TIMESHIFT examples
- Last UpdatedFeb 07, 2025
- 1 minute read
Example
The following expression shifts the time stamp of each flow rate value forward by one hour.
TIMESHIFT( Pump101.Flow, Hour )
Example 2
The following expression shifts the time stamp of the current time's minute value back by two minutes.
TIMESHIFT( SysTimeMin, -2 minute )
Represented as a query:
SELECT DateTime, Value, OPCQuality
FROM History
WHERE wwExpression = 'TIMESHIFT( SysTimeMin, -2 minute )'
Results:
|
DateTime |
Value |
OPCQuality |
|
2022-03-31 15:57:00.0000000 |
59 |
192 |
|
2022-03-31 15:58:00.0000000 |
0 |
192 |
|
2022-03-31 15:59:00.0000000 |
1 |
192 |
|
2022-03-31 16:00:00.0000000 |
2 |
192 |
|
... |
... |
... |