SQL
Ultimate SQL Mastery Quiz
Test your knowledge of SQL with our comprehensive quiz designed for aspiring database professionals and enthusiasts! Dive deep into the world of Structured Query Language and see how well you understand its concepts and commands.
Features:
- Challenging questions covering various SQL topics.
- Multiple choice format for easy answering.
- Immediate feedback on your performance.
What is the full form of SQL?
Structured Query List
Structure Query Language
Sample Query Language
None of these.
Which of the following are TCL commands?
COMMIT and ROLLBACK
UPDATE and TRUNCATE
SELECT and INSERT
GRANT and REVOKE
Which statement is used to delete all rows in a table without having the action logged?
DELETE
REMOVE
DROP
TRUNCATE
Which of the following is true about the HAVING clause?
Similar to the WHERE clause but is used for columns rather than groups.
Similar to WHERE clause but is used for rows rather than columns.
Similar to WHERE clause but is used for groups rather than rows.
Acts exactly like a WHERE clause
Which of the following is the correct order of a SQL statement?
SELECT, GROUP BY, WHERE, HAVING
SELECT, WHERE, GROUP BY, HAVING
SELECT, HAVING, WHERE, GROUP BY
SELECT, WHERE, HAVING, GROUP BY
What is the difference between a PRIMARY KEY and a UNIQUE KEY?
Primary key can store null value, whereas a unique key cannot store null value.
We can have only one primary key in a table while we can have multiple unique keys
Primary key cannot be a date variable whereas unique key can be
None of these
Which of the following are the synonyms for Column and ROW of a table? (1)Row = [Tuple, Record] (2) Column = [Field, Attribute] (3) Row = [Tuple, Attribute] (4) Columns = [Field, Record]
1 and 2
3 and 4
Only 1
Only 2
Which statement is used to get all data from the student table whose name starts with p?
SELECT * FROM student WHERE name LIKE '%p%';
SELECT * FROM student WHERE name LIKE '%p%';
SELECT * FROM student WHERE name LIKE '%p%';
SELECT * FROM student WHERE name LIKE '%p%';
What does SQL is used to perform operations on?
Update Records
Insert Records
Both A and B
None of the above
What is the work of CREATE command?
Using this command, you can remove or erase recorded information from a database table.
It enables you to create new databases, tables, table views, and other objects using this command.
Inserting records or data into the database tables is accomplished with this command. In addition to inserting records in single rows, we can insert records in multiple rows as well.
A single or multiple rows can be accessed using this command from one or more tables of a database. Using the WHERE clause with this command is also possible
Here which of the following displays the unique values of the column? SELECT ________ dept_name FROM instructor;
All
From
Distinct
Name
The query given below will not give an error. Which one of the following has to be replaced to get the desired output? SELECT ID, name, dept name, salary * 1.1 WHERE instructor;
Salary*1.1
ID
Where
Instructor
This Query can be replaced by which one of the following? SELECT name, course_id FROM instructor, teaches WHERE instructor_ID= teaches_ID;
Select name,course_id from teaches,instructor where instructor_id=course_id;
Select name, course_id from instructor natural join teaches;
Select name, course_id from instructor;
Select course_id from instructor join teaches;
Which of the following fields are displayed as output? SELECT * FROM employee WHERE salary>10000 AND dept_id=101;
Salary, dept_id
Employee
Salary
All the field of employee relation
This is Employee table.
Which of the following employee_id will be displayed for the given query?
Which of the following employee_id will be displayed for the given query?
SELECT * FROM employee WHERE employee_id>1009;
1009, 1001, 1018
1009, 1018
1001
1018
{"name":"SQL", "url":"https://www.quiz-maker.com/QPREVIEW","txt":"Test your knowledge of SQL with our comprehensive quiz designed for aspiring database professionals and enthusiasts! Dive deep into the world of Structured Query Language and see how well you understand its concepts and commands.Features:Challenging questions covering various SQL topics.Multiple choice format for easy answering.Immediate feedback on your performance.","img":"https:/images/course1.png"}