Events
Mar 17, 9 PM - Mar 21, 10 AM
Join the meetup series to build scalable AI solutions based on real-world use cases with fellow developers and experts.
Register nowThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
APPLIES TO:
NoSQL
Converts the specified date and time to a numeric timestamp. The timestamp is a signed numeric integer that measures the milliseconds since the Unix epoch.
DateTimeToTimestamp(<date_time>)
Description | |
---|---|
date_time |
A Coordinated Universal Time (UTC) date and time string in the ISO 8601 format YYYY-MM-DDThh:mm:ss.fffffffZ . |
Note
For more information on the ISO 8601 format, see ISO 8601.
Returns a signed numeric value, the current number of milliseconds that have elapsed since the Unix epoch (January 1, 1970).
Note
For more information on the Unix epoch, see Unix time.
The following example converts the date and time May 19, 2015 12:00 UTC to a timestamp.
SELECT VALUE {
timestamp: DateTimeToTimestamp("2015-05-19T12:00:00.0000000")
}
[
{
"timestamp": 1432036800000
}
]
undefined
if the date and time isn't a valid ISO 8601 date and time string.Events
Mar 17, 9 PM - Mar 21, 10 AM
Join the meetup series to build scalable AI solutions based on real-world use cases with fellow developers and experts.
Register now