USFormat.CharToDate

Previous Next

Converts a character string to a date.

Returns the result of the conversion as a date.

Syntax

SELECT USFormat.CharToDate(

       string

,      date-format-pattern

)

 

Both string and date-format-pattern are required. Date-format-pattern must be one of the USoft format patterns used for date values.

Example

SELECT USFormat.CharToDate(

         '12-MAR-2019'

,        'DD-MON-YYYY'

)