Understand time-stamp expressions
- Last UpdatedDec 13, 2024
- 1 minute read
- PI System
- PI Server 2018
- PI Server
To specify inputs for time stamps, you can enter time expressions that contain the following formats:
-
Fixed times
-
Reference-time abbreviations
-
Reference-time abbreviations with a time offset
-
Time offsets
Fixed times
A fixed time always represents the same time, regardless of the current time.
|
Input |
Meaning |
|---|---|
|
23-aug-12 15:00:00 |
3:00 p.m. on August 23, 2012 |
|
25-sep-12 |
00:00:00 (midnight) on September 25, 2012 |
Reference-time abbreviations
A reference-time abbreviation represents a time relative to the current time.
|
Input |
Meaning |
|---|---|
|
* |
Current time (now) |
|
3-1 or 3/1 |
00:00:00 (midnight) on March 1 of the current year |
|
2011 |
00:00:00 (midnight) on the current month and day in the year 2011 |
|
25 |
00:00:00 (midnight) on the 25th of the current month |
|
t |
00:00:00 (midnight) on the current date (today) |
|
y |
00:00:00 (midnight) on the previous date (yesterday) |
|
tue |
00:00:00 (midnight) on the most recent Tuesday |
Reference-time abbreviations with a time offset
When included with a reference-time abbreviation, a time offset adds or subtracts from the specified time.
|
Input |
Meaning |
|---|---|
|
*-1h |
One hour ago |
|
t+8h |
08:00:00 (8:00 a.m.) today |
|
y-8h |
16:00:00 (4:00 p.m.) the day before yesterday |
|
mon+14.5h |
14:30:00 (2:30 p.m.) last Monday |
|
sat-1m |
23:59:00 (11:59 p.m.) last Friday |
Time offsets
Entered alone, time offsets specify a time relative to an implied reference time. The implied reference time might be the current clock time or another time, depending on where you enter the expression.
|
Input |
Meaning |
|---|---|
|
-1d |
One day before the current time |
|
+6h |
Six hours after the current time |