Alter existing contraint

35 views
Skip to first unread message

anon34

unread,
Jun 1, 2015, 11:28:31 AM6/1/15
to fluentmigrato...@googlegroups.com
Hi,

is there a way to alter existing constraint? It was created with:

.WithColumn("ColumnName").AsInt32().NotNullable().ForeignKey("tblPatentName", "ParentId").OnDelete(Rule.Cascade)

but now i need to somehow alter it and use the .WillCascadeOnDelete(false).

Main reason for this is the circular cascade delete problem with SQL.
If not possible, any other idea how this can be solved. Deleting a column or recreating the whole table is not an option. 



Thank You.



Andrew Busby

unread,
Jun 1, 2015, 12:34:48 PM6/1/15
to fluentmigrato...@googlegroups.com

You can use the Alter.Constraint syntax

--
You received this message because you are subscribed to the Google Groups "FluentMigrator Google Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fluentmigrator-goog...@googlegroups.com.
To post to this group, send email to fluentmigrato...@googlegroups.com.
Visit this group at http://groups.google.com/group/fluentmigrator-google-group.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages