Question 11
EasyWhat is an alternate key?
- A.
A key that changes every day
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
DBMS
What is an alternate key?
A key that changes every day
A key made of every column
A candidate key that was not chosen as the primary key
A foreign key in another table
Sign up free to see the answer and a step-by-step explanation.
What does a UNIQUE constraint ensure?
No two rows have the same value in that column
The column links to another table
The column holds only numbers
The column cannot hold NULL
Sign up free to see the answer and a step-by-step explanation.
What does a NOT NULL constraint ensure?
Values in the column are unique
The column links to another table
The column holds only text
Every row must have a value in that column
Sign up free to see the answer and a step-by-step explanation.
What does a CHECK constraint do?
Checks the spelling of data
Counts the rows
Creates a backup of the table
Makes sure every value in a column satisfies a given condition
Sign up free to see the answer and a step-by-step explanation.
What is a relation schema?
A list of all users
The relation's name together with its list of attributes, such as Student(roll, name, city)
A diagram of the hard disk
The data stored in a relation
Sign up free to see the answer and a step-by-step explanation.
A relation Student(roll, name, city, phone) has how many attributes?
5
1
4
3
Sign up free to see the answer and a step-by-step explanation.
Why can't a relation contain two identical rows?
Rows must be in sorted order
Identical rows use too much space
SQL cannot store text twice
A relation is a set of tuples, and a set has no duplicates
Sign up free to see the answer and a step-by-step explanation.
Does the order of rows matter in a relation?
Yes, the first row is the most important
Only if the table is small
Yes, rows must be sorted by the key
No, the rows of a relation are unordered
Sign up free to see the answer and a step-by-step explanation.
In a one-to-many relationship between Department and Employee, which table holds the foreign key?
Department, the 'one' side
Both tables
Employee, the 'many' side
A separate third table always
Sign up free to see the answer and a step-by-step explanation.
What does a DEFAULT constraint do?
Supplies a value for a column when an insert doesn't give one
Deletes default rows
Prevents NULL values
Makes a column the primary key
Sign up free to see the answer and a step-by-step explanation.