Check foreign key relations database to fix database
There are some foreign key relations in the database that are not correct anymore.
I found the following 2 queries that show already inconsistencies, but there meight be more of them
Submitted by chris melman on 23 October 2013 at 12:58SELECT _DBLP_Publication.id, _DBLP_Publication.DBLP_Publication_publication FROM _DBLP_Publication LEFT JOIN _Publication ON _DBLP_Publication.DBLP_Publication_publication = _Publication.id WHERE _Publication.id IS NULL and _DBLP_Publication.DBLP_Publication_publication is not null ; SELECT _AbstractAuthor.id,_AbstractAuthor.Author_publication, _Publication.id FROM _AbstractAuthor LEFT JOIN _Publication ON _AbstractAuthor.Author_publication = _Publication.id WHERE _Publication.id IS NULL and _AbstractAuthor.Author_publication is not null ;
Log in to post comments