Relative Date Time node
Description
The Relative date time node represents the date and time occurring a number of time units before/after a specific date and time, e.g. 1 hour 30 minutes before end of day, 2 days 8 hours from now
Usage
The Relative date time node is an input, so it can be added to the segments of comparison nodes.
It can be:
-
added to these comparison nodes:
- Equals
- Greater than
- Less than
- Not Equals
-
compared against an Attribute node (of Relative date time type)
Configuration
- Parameter - select a compatible parameter to use as a placeholder value (if any have been defined in the query).
- Relative to - the default value is Now. To change it, select it and choose from the list of dynamic dates.
- Relative date time - enable Before if required and then input the desired number of time units.
Example
Fetch all assets that were edited today
In full detail:
Fetch items of the Assets interface where their Last edit date property is greater than 0 seconds from Start of Day
See JSON code
{
"type": "Query",
"properties": {
"collectionCode": "Live",
"dodiCode": "designInterfaces_assets"
},
"children": [
{
"type": "GreaterThan",
"children": [
{
"type": "ItemProperty",
"properties": {
"itemPropertyName": "lastEditDate"
}
},
{
"type": "RelativeDateTime",
"properties": {
"relativeTo": "Now",
"value": ["0.00:00:00.000"]
}
}
]
}
]
}