What is the purpose of the COUNT() function in SQL?
COUNT()
Returns the number of rows in a table
Finds the minimum value in a column
Returns the average value of a column
Calculates the sum of values in a column
Which keyword is used in conjunction with the UPDATE statement to specify the conditions for updating rows?
CONDITION
IF
WHEN
WHERE
Which aggregate function would you use to find the highest value in a column?
MAX()
MIN()
AVG()
SUM()
What is the function of the SQL 'WHERE' clause?
To group rows with the same value in a certain column
To order the results of a query
To limit the number of rows returned by a query
To filter records based on a specified condition
How would you convert the text 'hello world' to uppercase in SQL?
TO_UPPER('hello world')
MAKE_UPPER('hello world')
UPPER('hello world')
UCASE('hello world')
What type of join returns all rows from the left table, even if there are no matching rows in the right table?
RIGHT JOIN
FULL JOIN
LEFT JOIN
INNER JOIN
What is the result of SELECT NOW(); in SQL?
SELECT NOW();
An error message
Current date
Current time
Current date and time
Which SQL clause is used to sort the result set?
SORT BY
ORDER
SORT
ORDER BY
Which type of subquery is used to check if a value exists in a list of values returned by another query?
Nested Subquery
IN Subquery
EXISTS Subquery
Correlated Subquery
You want to find customers who have placed orders in the last month. You have two tables: 'Customers' and 'Orders'. Which subquery type would be most efficient to achieve this?
Any of the above would be equally efficient.