Date-time
Explore what information is available for date-time.
This type represents a specific date and time as defined by the ISO 8601 standard.
Although date-time values have no literal syntax, you can use the cast modifier to convert a string into a date-time value.
Date-time values refer to a specific point on the timeline, even if they are not associated with a time zone. With CQL, you do not have to worry about time zones because conversions consider the default time zone configured in your application, making the process seamless.
Range
The range of valid date times is from -999999999-01-01T00:00:00 to 999999999-12-31T23:59:59.999999999.
Properties
These are the available properties:
- day
The day of the month, from 1 to 31.
- weekday
The name of the day of the week, such as "monday" or "tuesday".
The name is always in lowercase and in English.
- month
The month of the year, from 1 to 12.
- year
The year, from -999999999 to 999999999.
This value follows the ISO 8601 standard and uses the proleptic numbering system. Therefore, year 1 is preceded by year 0, then by year -1.
- hour
The hour of the day, from 0 to 23.
- minute
The minute of the hour, from 0 to 59.
- second
The second of the minute, from 0 to 59.
- milli
The millisecond of the second, from 0 to 999.
- micro
The microsecond of the second, from 0 to 999999.
- nano
The nanosecond of the second, from 0 to 999999999.