Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Foreign key constraint blocks (final) tab deletion #42

Open
MaiklT opened this issue Dec 7, 2023 · 0 comments
Open

Foreign key constraint blocks (final) tab deletion #42

MaiklT opened this issue Dec 7, 2023 · 0 comments

Comments

@MaiklT
Copy link

MaiklT commented Dec 7, 2023

When trying to delete a page from the trash bin I run into an error that tells me to check my internet connection... As that can't be the reason I investigated a bit and found out that there is a foreign key constraint in the table Community_Visits (FK_Community_Visits_Tabs) blocking the deletion.

When deleting all records in this table with tab_id = (TabId of this page from the Tabs table) and restarting the app pool, the page can be deleted from the trash bin.

It is in fact done from the wrong side (should be from the master = Tabs table to the Community Visits table with the ON DELETE CASCADE option - but this is a change to the core system, and therefore not a good practice for modules).

The constraint should be removed, and to keep that table "clean" a task could check from time to time if all values of the tab_id column exist in the Tabs table and delete these records if not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant