You are viewing content for 5.1 | 5.0 | 4.9 | 4.8 | 4.7 | 4.6 | 4.5 | 4.4 | 4.3 | Previous Releases


addDays

Returns a new date after adding an integer number of days to a given date.

Example

Add four days to the date 11:55:12 pm December 24, 2001.

addDays(timestamp("2001-12-24 23:55:12.000"), 4)

This results in the date “2001-12-28”.

Syntax

addDays(expr t, int days)
  • t : expression evaluating to timestamp
  • days : int number of days (+/-) to add to t

Returns

timestamp

Notes

Function addDays returns a new date after adding an integer number of days to it. The number of days can be positive or negative. Function addDays adds an integer number of days (+/-) to a date, returning a new date.


© Incorta, Inc. All Rights Reserved.