ToTimestamp
Converts a date or a date and time value into a timestamp.
Variants
ToTimestamp(Date date)
Returns a timestamp that corresponds to 12:00 am of the given date in the local time zone (midnight at the beginning of the date).
Parameters
- date
- The date value you want to convert.
Returns
Timestamp
Examples
ToTimestamp([Date Column])
takes the date value "4/30/2013" stored in the Date Column and returns the timestamp value "4/30/2013 12:00:00 AM".
ToTimestamp(Date date, Time time)
Returns a timestamp that corresponds to the given time on the given date in the local time zone.
Parameters
- date
- The date value you want to convert.
- time
- The time value you want to convert.
Returns
Timestamp
Examples
ToTimestamp([Date Column], [Time Column])
takes the date value "4/30/2013" stored in the Date Column and the time value "10:20:00 AM" stored in the Time Column, and returns the timestamp value "4/30/2013 10:20:00 AM".