The DB2® data server resolves any unqualified reference to the DUAL table as a built-in view that returns one row and one column that is named DUMMY, whose value is 'X'.
db2set DB2_COMPATIBILITY_VECTOR=02
db2stop
db2start
To take full advantage of the DB2 compatibility features for Oracle applications, the recommended setting for the DB2_COMPATIBILITY_VECTOR is ORA, which sets all of the compatibility bits.
Unqualified table references to the DUAL table are resolved as SYSIBM.DUAL.
If a user-defined table named DUAL exists, the DB2 server resolves a table reference to the user-defined table only if the reference is explicitly qualified.
SELECT RAND() AS RANDOM_NUMBER FROM DUAL
SET SCHEMA = MYSCHEMA;
SELECT CURRENT SCHEMA AS CURRENT_SCHEMA FROM DUAL;