A populated database doesn't have cascade constraints after executing migrations

Johan Andrew 14 days ago

bridge tables (tc_user_*, tc_device_*) don't have all those foreign key on delete constraints mentioned here

I realised this problem after discovering orphan records from those tables. An example, an user deleted from the database but, it still uses the relationship on tc_user_notifications with that deleted userid.

my traccar.xml is configured to read changelog-master.xml.

logs.png

tc_user_user.png
changelog.png

What can I do to solve this issue, it's strange the fact that happened to my tables, idk why

Anton Tananaev 14 days ago

Just add those constraints manually.