Sqlite ON DELETE CASCADE #1219
Unanswered
Christian-Fenzl
asked this question in
Q&A
Replies: 1 comment
-
Yes, DMS is not a database generator, so the client sql generation is pretty limited. And as you say, the DELETE CASCADE is not tested (and will not) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
my server database is MS SQL SERVER (created by EF Core Migrations) and the client database is Sqlite. The Sqlite database is completely created by the first sync with Dotmim.Sync.
The server database contains some parent/child relationships with enabled ON DELETE CASCADE on their foreign keys. This ON DELETE CASCADE is missing in the created Sqlite database, even with enabled "Foreign Keys=True;" in the connection string for the Sqlite database.
Is that by design to not include the ON DELETE CASCADE in the synched client database? I read some advise to better not use it with Dotmim.Sync but nothing really clear.
So is it better to not rely on this option and delete the childs records explicitly by myself?
Or how can I enable the creation during the first sync?
Beta Was this translation helpful? Give feedback.
All reactions