Use the ALL condition in conjunction with a comparison operators to compare a single value to the data values produced by the subquery.
expression compare [ NOT ] ALL ( subquery )
compare: = | > | < | >= | <= | <> | != | !< | !>
UltraLite uses the specified comparison operator to compare the test value to each data value in the result set. If all the comparisons yield TRUE results, the ALL test returns TRUE.
Find the order and customer IDs of those orders placed after all products of order #2001 were shipped.
SELECT ID, CustomerID FROM SalesOrders WHERE OrderDate > ALL ( SELECT ShipDate FROM SalesOrderItems WHERE ID=2001); |
Discuss this page in DocCommentXchange. Send feedback about this page using email. |
Copyright © 2009, iAnywhere Solutions, Inc. - SQL Anywhere 11.0.1 |