Q1.
Which SQL statement is used to retrieve unique values from a column?
1
1
SELECT DISTINCT column_name FROM table_name;
2
SELECT UNIQUE column_name FROM table_name;
3
SELECT DIFFERENT column_name FROM table_name;
4
SELECT column_name FROM table_name WHERE DISTINCT;
Q2.
What does SQL stand for?
1
1
Structured Query Language
2
Sequential Query Language
3
System Query Language
4
Standardized Query Logic
Q3.
Which SQL command is used to remove all records from a table without deleting the table structure?
1
1
DELETE
2
DROP
3
CLEAR
4
TRUNCATE
Q4.
Which SQL join returns only the matching rows from both tables?
1
1
LEFT JOIN
2
RIGHT JOIN
3
FULL JOIN
4
INNER JOIN
Q5.
Which SQL constraint ensures that a column cannot have NULL values?
1
1
UNIQUE
2
NOT NULL
3
CHECK
4
PRIMARY KEY
Q6.
Which of the following is NOT an SQL aggregate function?
1
1
SUM()
2
AVG()
3
COUNT()
4
CONCAT()
Q7.
Which SQL clause is used to filter records from a table?
1
1
WHERE
2
GROUP BY
3
ORDER BY
4
HAVING
Q8.
Which SQL JOIN returns all records from the left table and only matching records from the right table?
1
1
LEFT JOIN
2
RIGHT JOIN
3
FULL JOIN
4
INNER JOIN
Q9.
Which constraint is used to ensure that all values in a column are unique?
1
1
NOT NULL
2
UNIQUE
3
FOREIGN KEY
4
CHECK
Q10.
Which SQL clause is used with aggregate functions to group results?
1
1
ORDER BY
2
GROUP BY
3
HAVING
4
DISTINCT