Tips for folks switching between DB2 and Oracle
Some Oracle and DB2 differences that are hard to find in the manuals:
Generic 1 row table for fast queries:
Oracle: dual
DB2: sysibm.sysdummy1
Current date and time for the server:
Oracle: select to_char(sysdate, 'yyyy-mm-dd hh24:mi:ss') from dual;
DB2: select current_time, current_date from sysibm.sysdummy1;
Delete a whole table, fast:
Oracle: truncate table x
DB2: load an empty file into the table
Generic 1 row table for fast queries:
Oracle: dual
DB2: sysibm.sysdummy1
Current date and time for the server:
Oracle: select to_char(sysdate, 'yyyy-mm-dd hh24:mi:ss') from dual;
DB2: select current_time, current_date from sysibm.sysdummy1;
Delete a whole table, fast:
Oracle: truncate table x
DB2: load an empty file into the table
0 Comments:
Post a Comment
<< Home