OCP-1Z0-051-Question Analysis-28th question

Source: Internet
Author: User

28. Which two statements are true regarding constraints? (Choose two .)
A. A foreign key cannot contain NULL values.
B. A column with the UNIQUE constraint can contain NULL values.
C. A constraint is enforced only for the INSERT operation on a table.
D. A constraint can be disabled even if the constraint column contains data.
E. All constraints can be defined at the column level as well as the table level.


Answer: BD


A: foreign key constraints cannot contain null values (incorrect, only non-empty constraints and primary key constraints cannot contain null values ).
B: The unique constraint can contain NULL values (correct, because NULL <> NULL)
C: The constraints on a table only apply to the insert operation (errors, Update, and delete also apply ).
D: the constraints on the field can be disabled (correct) even if the field contains data)
E: All constraints can be defined at the column level and table level (incorrect, Not Null can only be defined at the column level ).

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.