10 likes | 125 Vues
This document outlines a structured query for database records involving compatibility checks in the context of versions V1 and V2. It examines how to identify records in the "Verträglichkeit" (compatibility) table where specific conditions are not met. By filtering based on entry numbers (ANr) and storage locations (Lagerort), the query aims to find entries in V1 that do not have corresponding entries in V2 matching both the ANr and storage location number (LoNr). This approach assists in ensuring data integrity and proper record management.
E N D
Division (2) V1 in Verträglichkeit, V2 in Verträglichkeit, LO in Lagerort;V1.ANr where LO ($ V2 (V2.ANr = V1.ANr V2.LoNr = LO.LoNr)); V1 in Verträglichkeit, V2 in Verträglichkeit, LO in Lagerort;V1.ANr where " LO ($ V2 (V2.ANr = V1.ANr V2.LoNr = LO.LoNr)); select ANr from Verträglichkeit V1 wherenot exists ( select from Lagerort Lo where not exists ( select from Verträglichkeit V2 where V2.ANr = V1.ANr and V2.LoNr = Lo.LoNr));