DB2 Scalar functions - ADD_DAYS
The ADD_DAYS function returns a datetime value that represents the first argument plus a specified number of days.
The schema is SYSIBM.
The result of the function is a timestamp with the same precision as expression, if expression is a timestamp. Otherwise, the result of the function is a date. If any argument can be null, the result can be null; if any argument is null, the result is the null value.
SET :ADD_DAY = ADD_DAYS(CURRENT_DATE, 1)
SET :ADD_DAY = ADD_DAYS(:DATE,3)
SET :DATEHV = DATE('2008-2-28') + 4 DAYS SET :DATEHV = ADD_DAYS('2008-2-28', 4)
SET :DATEHV = DATE('2008-2-29') + 4 DAYS SET :DATEHV = ADD_DAYS('2008-2-29', 4)
SET :ADD_DAY = ADD_DAYS(:DATE,-3)