Page 305 - Information_Practice_Fliipbook_Class11
P. 305
gender CHAR(1),
PRIMARY KEY (student_id)
);
a. What will be the degree of student table?
i. 30
ii. 1
iii. 3
iv. 4
b. What does 'name' represent in the above code snippet?
i. a table
ii. a row
iii. a column
iv. a database
c. What is true about the following SQL statement?
SelecT * fROM student;
i. Displays contents of table 'student'
ii. Displays column names and contents of table 'student'
iii. Results in error as improper case has been used
iv. Displays only the column names of table 'student'
d. What will be the output of following query?
INSERT INTO student
VALUES ("Suhana",109,'F'),
VALUES ("Rivaan",102,'M'),
VALUES ("Atharv",103,'M'),
VALUES ("Rishika",105,'F'),
VALUES ("Garvit",104,'M'),
VALUES ("Shaurya",109,'M');
i. Error
ii. No Error
iii. Depends on compiler
iv. Successful completion of the query
e. In the following query how many rows will be deleted?
DELETE student
WHERE student_id=109;
i. 1 row
ii. All the rows where student ID is equal to 109
iii. No row will be deleted
iv. 2 rows
Ans. a. iii. 3
b. iii. a column
c. i. Displays contents of table ‘student’ and ii. Displays column names and contents of table ‘student’.
d. i. Error: we cannot use VALUES keyword multiple times in a single INSERT statement.
e. i. 1 row
16. Fill in the blanks:
a. _____________________declares that an index in one table is related to that in another table.
i. Primary Key
ii. Foreign Key
iii. Composite Key
iv. Secondary Key
b. The symbol Asterisk (*) in a select query retrieves ____________.
i. All data from the table
Database Concepts and the Structured Query Language 291

