Skip to content

parseToTimestamp

Description

Warning

parseToTimestamp is depricated. Use parseTimestamp instead.

Returns a timestamp parsed from a date/time string with an optional format specification and time zone override. See parseTimestamp for details.

Syntax

Like many functions in DataPrime, parseToTimestamp supports two notations, function and method notation. These interchangeable forms allow flexibility in how you structure expressions.

parseToTimestamp(string: string, format?: string, tz?: string): timestamp
(string: string).parseToTimestamp(format?: string, tz?: string): timestamp

Arguments

NameTypeRequiredDescription
stringstringtrueThe date/time string to parse
formatstringfalseThe format of the input string. Defaults to auto
tzstringfalseA valid time zone string