Previous Topic: OQ142003Next Topic: OQ142005


OQ142004

The OR logical operator is not valid for set names.

Reason:

You cannot use the OR logical operator on a set name specified in a SELECT statement's WHERE clause. When retrieving records that optionally participate in sets, consider the example below, where records A, B, and C are related in the following sets:

To return all B occurrences that are owned by any A or C occurrence, issue the following request:

SELECT *
  FROM B
   WHERE EXISTS
      (SELECT *
        FROM A
         WHERE A-B)
     OR EXISTS
      (SELECT *
        FROM C
         WHERE C-B)

Module:

OLQSSQLO

Severity:

0