Dear Cspro Developer Team,
I would like to delete lot of empty cases in Csentry and avoid them to be synchronized. In my applications, a case is empty if case label ="";
So, i could use sqlquery in a menu: delete from cases where label="";
But, it require to modify foreign constraint with on delete cascade in Csdb...
Greg informed me months ago, a way to delete case under conditions. But, i don't know if can use it with non ID item values.
Right now, univers can't use advanced conditions for synchronisation. It's based only on ID items starting number... so i can't sync only cases where case.label="";
Please help me with.
Best regards,
Please forget previous message since the application had a lock deleted in pff.
Delete Case in Csentry Android
Delete Case in Csentry Android
G.VOLNY, a CSProuser from Haiti, since 2004
-
- Posts: 1796
- Joined: December 5th, 2011, 11:27 pm
- Location: Washington, DC
Re: Delete Case in Csentry Android
You can temporarily turn off the use of foreign keys:
However, I definitely don't suggest this. You really shouldn't be modifying the .csdb file using SQLite statements. I would analyze your application and come up with a system so that you're not adding cases that you don't want synced. Reworking your workflow, rather than editing the file with SQLite, is the best option.PRAGMA foreign_keys = 0;
DELETE FROM cases WHERE label = "";
PRAGMA foreign_keys = 1;
Re: Delete Case in Csentry Android
Thank you Greg. I understand that the best way is to give us a ways to use a more advanced universe for sync. In the meantime, using disable and enable PRAGMA foreign_key is the best solution.
Best Regards,
Best Regards,
G.VOLNY, a CSProuser from Haiti, since 2004