How To/

-- date/time playing in db2
--source:
--http://www.ibm.com/developerworks/db2/library/techarticle/0211yip/0211yip3.html

SELECT current date FROM sysibm.sysdummy1;
--2008-09-17

SELECT current timestamp FROM sysibm.sysdummy1;
--2008-09-17-23.41.51.335024

SELECT YEAR (current timestamp) FROM sysibm.sysdummy1;
--2008
--SEE ALSO: YEAR(), MONTH(), DAY(), HOUR(), MINUTE(), SECOND(), MICROSECOND()


SELECT DATE (current timestamp) FROM sysibm.sysdummy1;
--2008-09-17

SELECT TIME (current timestamp) FROM sysibm.sysdummy1; 
--23:47:12

SELECT current timestamp - 6 MONTHS FROM sysibm.sysdummy1;
--2008-09-17-23.41.51.335024
--SEE ALSO: (+/-) 1 YEAR, X YEARS, X MONTH[S], X DAY[S], X HOUR[S], X MINUTE[S], X SECOND[S]