%incrdate() Function

Top  Previous  Next

%incrdate() function is used to increase/decrease a date value.

Syntax:

%incrdate(date/timetime-unit, amount)
 

date/time

Date/Time value in milliseconds. The now() function that returns the current date/time can be used in this parameter.

time-unit

The increate/decrease unit. The valid values are:
'YEAR', 'MONTH', 'DAY', 'HOUR', 'MINUTE', 'SECOND' and 'MILLISECOND'

amount

The increate/decrease amount.

 

Examples:

%incrdate(now(),'DAY',-5)    %// 5 day before of the current time

%fmtdate( incrdate(now(),'MONTH',1), 'yyyy-mm-dd')  %// 1 month after the current time

 

See %fmtdate()