Edit

Date Operators

The date operators are used to perform arithmetic on dates. One of the operands must be a number, and is treated as a number of days.

SymbolOperationUsage
+day additionA + B
A must be of type date, and B must be a number.
The result is a date B days after A.
For example: '21/2/68' + 5 gives 26/2/68.
-day subtractionA - B
A must be of type date, and B must be a number.
The result is a date B days before A.
For example: '21/2/68' - 5 gives 16/2/68.

Note: When comparing a time with a date, the date is evaluated as midnight on that date (i.e. time zero). Thus a search of (for example):

        transaction.timeposted > '1/1/2014'

will find every transaction posted after midnight on 1st January, which will (perhaps counter-intuitively) include all those posted on the 1st Jan. To omit these from the search, add one to the date, e.g:

        transaction.timeposted >= targetDate+1