Computer AwarenessHardIBPS SO IT · SBI PO

An ORDERS table has CustomerID as a foreign key referring to CUSTOMER. A clerk tries to insert an order with CustomerID 9999, which does not exist in CUSTOMER. Which constraint is violated?

  1. A. Entity integrity
  2. B. Domain integrity
  3. C. Uniqueness of the primary key
  4. D. Referential integrity

Correct answer: D. Referential integrity

Referential integrity requires every foreign-key value to match an existing primary key (or be NULL). Entity integrity concerns NULLs in the primary key of the same table.

हिंदी में

ORDERS तालिका में CustomerID एक फ़ॉरेन की है जो CUSTOMER को संदर्भित करती है। एक क्लर्क CustomerID 9999 वाला ऑर्डर डालने का प्रयास करता है, जो CUSTOMER में मौजूद नहीं है। कौन-सा प्रतिबंध भंग होता है?

  1. A. एंटिटी इंटेग्रिटी
  2. B. डोमेन इंटेग्रिटी
  3. C. प्राइमरी की की अद्वितीयता
  4. D. रेफ़रेंशियल इंटेग्रिटी

उत्तर: D. रेफ़रेंशियल इंटेग्रिटी के अनुसार प्रत्येक फ़ॉरेन-की मान किसी मौजूदा प्राइमरी की से मेल खाना चाहिए (या NULL होना चाहिए)। एंटिटी इंटेग्रिटी उसी तालिका की प्राइमरी की में NULL से संबंधित है।

More Computer Awareness questions

Exams that ask this topic