Runtime Type : Types : dateTime
Changes Locked Out for Planned Maintenance Primitive type that stores a date and time in the format specified by the ISO 8601 standard. The date is represented in the form "yyyy-mm-ddThh:mm:ss.sss", optionally followed by a time zone indicator in the form "+/-hh:mm".
Contents |
SOAP Formatted String
If the string is a SOAP formatted string, than it is parsed as such (see ISO8601 standard, which was adopted by SOAP as the SOAP timeinstant standard). Below is a synopsis of the ISO standard.Format
-CENTURYYEAR-MONTH-DAYTHOUR:MINUTE:SECOND.SECONDPRECISION(+ -)HOUR:MINUTE
Example
[-]1900-01-00T01:01:01[.0+](+|-)00:00
| CENTURY | 00-99 (two character) |
| YEAR |
00-99 (two character) |
| MONTH |
01-12 (two character) |
| DAY |
01-31 (two character) |
| HOUR | 00-23 (two character) |
| MINUTES | 00-59 (two character) |
| SECONDS | 00-59 (two character) |
| TIMEZONE OFFSET | |
| HOUR |
00-23 (two character) |
| MINUTE |
00-59 (two character) |
Note: You can use the space ( ) character in place of the hyphen (-) so that strings originating in databases are supported.
Using the "compute" Prefix
If you prefix the string with the value compute: then you can perform various calculations on the date and time (you must include the quotes as shown in the examples).
Example 1:
start = “compute:now;minute:+30;”
is equivalent to setting the start field to the current time plus 30 minutes
Example 2:
start = “compute:minute:+30”
is equivalent to adding 30 minutes to the start time.
The legend for the computational command is as follows:
| century | set the century of the datetime (high order digits of the full year) |
| decade |
set the year of the datetime (the two lower order digits of the full year |
| now |
compute the current time in the client's time zone (the offset is set tot he client at that point) |
| hour |
set the hour |
| minute |
set the minute |
| day |
set the day |
| month |
set the month |
| year |
set the full year |
| second |
set the seconds |
| today |
compute the current time in the client's time zone (the offset is set to the client at that point) |
| gmttoday |
compute the current time in GMT |
| gmtnow |
compute the current time in GMT |
| setzone |
set the zone offset (this effectively modifies the relative offset form GMT) |
| transform |
forces the machinery to compute the duration arithmetic and clears the duration (see below) |
| normalize |
sets the zone of the datetime to the client offset then normalizes the value to GMT |
| translate |
adjusts the datetime to the client offset |
Note: Placing a plus (+) or minus (-) in front of the value for century, decade, hour,
minute, day, month, or year causes the value to be set on a duration
that is computed against the datetime after the commands are parsed. The exception is that if the command transform is
invoked, then the duration is applied to the datetime the moment the
command is encountered in the parse.
For example, the following command adds 6 hours and 30 minutes to the time:
"compute:minute:+30;hour:+6;"
At the end of the parse, if there is a duration that needs to be applied, then the datetime is "transformed" at that point (the transform command clears out the duration so this is not applied more than once).
After that, the datetime is adjusted back to GMT (you are encouraged to keep your times on the server in GMT).
See Also
date
gDay
gMonth
gMonthDay
gYear
gYearMonth
time
TimeUtil
Inherits From
root→dateTime
Fields
| dateTime value | Stores the date-time value |



