Table of Contents
Voici quelques requêtes SQL permettant de contrôler l'état d'un base AIT :
Voici quelques requêtes pour vérifier que des lignes les jointures entre tag soit toujours vrai.
SELECT tagged.* FROM tagged LEFT JOIN tag ON tagged.item_id=tag.id WHERE tag.id IS NULL SELECT tagged.* FROM tagged LEFT JOIN tag ON tagged.tag_id=tag.id WHERE tag.id IS NULL SELECT a.* FROM tag a LEFT JOIN tag b ON a.type=b.id WHERE a.id <> 1 and a.id <> 2 and b.id IS NULL