MCQ IN COMPUTER SCIENCE & ENGINEERING

COMPUTER SCIENCE AND ENGINEERING

SQL

Question [CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
We can’t use subqueries with which of the clauses given below?
A
SELECT
B
UPDATE
C
DELETE
D
None of these
Explanation: 

Detailed explanation-1: -The GROUP BY clause is not required in the sub-query. A function cannot be used in a sub-query SELECT statement.

Detailed explanation-2: -It can’t include a COMPUTE or FOR BROWSE clause, and may only include an ORDER BY clause when a TOP clause is also specified. A subquery can be nested inside the WHERE or HAVING clause of an outer SELECT, INSERT, UPDATE, or DELETE statement, or inside another subquery.

Detailed explanation-3: -You can place the Subquery in a number of SQL clauses: WHERE clause, HAVING clause, FROM clause. Subqueries can be used with SELECT, UPDATE, INSERT, DELETE statements along with expression operator. It could be equality operator or comparison operator such as =, >, =, <= and Like operator.

Detailed explanation-4: -Answer: C. Multi-row operators cannot be used in single-row sub-queries and vice versa.

There is 1 question to complete.