You are viewing the documentation for Blueriq 17. Documentation for other versions is available in our documentation directory.
SUBTRACT PERIOD FROM DATETIME
Calculates a new dateTime by subtracting a specified period from a specified dateTime.
Syntax
dateTime - number period
Inputs
- dateTime - The dateTime that you want to subtract the specified period from.
- number - Specifies how many periods you want to subtract from the dateTime.
- period - A keyword that specifies which time unit to subtract. Valid units are
DAYS, WEEKS, MONTHS, YEARS, HOURS, MINUTES
andSECONDS
.
Return type
- dateTime
Examples
Expression | Result | Type |
---|---|---|
01-01-2015 13:23:04 – 1 HOURS | 01-01-2015 12:23:04 | DateTime |
01-01-2015 13:23:04 – 25 HOURS | 31-12-2014 12:23:04 | DateTime |
01-01-2015 13:23:04 – 60 SECONDS | 01-01-2015 13:22:04 | DateTime |
01-01-2015 13:23:04 – 1 MINUTES | 01-01-2015 13:22:04 | DateTime |
Overview
Content Tools