Helpful Information
 
 
Category: DB2 Development
DB2 - equivalent of Oracle's sysdate ?

Haven't found this one yet - whats the DB2 equivalent of Oracle's sysdate function ?

DB2 has the standard function CURRENT_DATE.

DB2 has the standard function CURRENT_DATE.

sweet - thx mucho swampBoogie :D

Actually it is CURRENT DATE (no underscore, CURRENT_DATE is for MySQL). You can also use CURRENT TIME or CURRENT TIMESTAMP depending on your needs.

Yes, you are right. My mistake.

CURRENT DATE, etc. is correct. Also be advised that you can have some troubles when pulling from DB2 - valid date range
is 0001-01-01 to 12-31-9999, the lower end being beyond what ADO considers valid dates. Convert to
CHAR(SOMEDATE) when extracting. Likewise, timestamps can be problematic...

fv










privacy (GDPR)