Back to course home
0% completed
Vote For New Content
Quiz
Question 1
Which of the following are characteristics of a relational database?
Choose all correct options
Data is stored in tables.
Tables must have primary keys.
Relationships are represented by foreign keys.
Tables are hierarchical in structure.
Question 2
What is the main difference between a candidate key and a primary key?
A
Candidate keys are always composite.
B
Candidate keys can serve as a primary key, but only one is chosen.
C
Candidate keys are optional, but primary keys are required.
D
Candidate keys are used for foreign key relationships.
Question 3
In a Bookstore database, a Books table has the following attributes:
ISBN | Title | Author | Price |
---|---|---|---|
978-123456 | Learning SQL | John Doe | 39.99 |
978-654321 | DBMS Basics | Jane Smith | 49.99 |
If you want to ensure that all prices are positive, which integrity constraint should you apply?
A
Domain Integrity
B
Referential Integrity
C
Entity Integrity
D
Functional Dependency
Question 4
Given the following schema for Orders:
Order_ID | Customer_ID | Order_Date | Total_Amount |
---|---|---|---|
O101 | C001 | 2024-01-15 | 100.50 |
O102 | C002 | 2024-01-16 | 150.75 |
Which attribute(s) should you choose as a primary key?
A
Customer_ID
B
Order_ID
C
Both Order_ID and Customer_ID
D
None
Question 5
You have the following Employee table:
Emp_ID | Emp_Name | Dept_ID |
---|---|---|
101 | Alice | D01 |
102 | Bob | D02 |
103 | Charlie | NULL |
Which relational integrity constraint is violated if a Dept_ID in the Employee table must reference an existing Department table?
A
Entity Integrity
B
Referential Integrity
C
Domain Integrity
D
Functional Dependency
.....
.....
.....
Like the course? Get enrolled and start learning!
Table of Contents
Contents are not accessible
Contents are not accessible
Contents are not accessible
Contents are not accessible
Contents are not accessible