Loading lesson path
operator is used to compare a value to every value returned by a subquery.
Formula
operator evaluates to TRUE if at least one value in the subquery result - set meet the condition.column_name(s)
table_name
column_name operator ANY ( subquery
);The operator must be a standard comparison operator (=, <>, !=, >, >=, <, or <=).
"Products" table in the Northwind sample database:
18.00
19.00
10.00
22.00
"OrderDetails" table:
11 12
42 10
72
14
The following SQL returns the ProductName if it finds ANY records in the "OrderDetails" table that has Quantity equal to 10 (this will return TRUE because the Quantity column has some values of 10):