| Author |
Message |
Authorized_
Joined: 02 Mar 2011 Posts: 5
|
Posted: Mon Mar 14, 2011 4:06 pm Post subject: on delete cascade while datasynchronisation |
|
|
Hello,
Sometimes the SDK gives a foreign key error. Because the rows have references to other tables. Which is quite normal.
But is it possible to delete also these foreign rows at once?
Thank you in advance
Gillian |
|
| Back to top |
|
 |
Brian Donahue
Joined: 23 Aug 2004 Posts: 6344 Location: Red Gate Software
|
Posted: Tue Mar 15, 2011 6:21 pm Post subject: |
|
|
Hi Gillian,
I believe you can fix this error easily by using the SqlOptions.DisableKeys option in your EngineDataCompareOptions class. Don't forget to specify this in mappings, session, and SqlProvider classes or you may see inconsistent behavior.
Because SQL Data Compare Engine scripts updates a table at a time, it's necessary to temporarily disable the foreign keys and restore them after the synchronization. _________________ Brian Donahue
Technical Support
Red Gate Software Ltd.
44 (0)870 160 0037 ext 8521
US and CAN 1-866-RED GATE ext 8521 |
|
| Back to top |
|
 |
|
|
All times are GMT + 1 Hour
|
| Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group