You are viewing the documentation for Blueriq 14. Documentation for other versions is available in our documentation directory.

DATE


Converts a value of another data type into a date. 


Syntax

DATE(string value, [format])
DATE(dateTime value)


Inputs

  • value - The value of the data type that is converted to date. 

  • format (optional) - The format used for conversion. Format must be enclosed by quotes, e.g. "yyyy-MM-dd". For more info on specifying date format patterns, please see Date and time formats or patterns


Default formats

For all conversion functions that use a string as parameter, the [format] describes the format in which the input string value parameter is in. When not specifying a format, by default this format is used: 

  • string to date - yyyy-MM-dd. 


Return type

  • date


Examples

  • DATE("2021-02-18") results in a date value of 18-02-2021 (default format is used). 
  • DATE("01/01/2021", "dd/MM/yyyy") results in a date value of 01-01-2021 (specified format is used). 

Back to Top