str_to_jodatime
Converts a Joda-formatted string into a DATETIME value in the specified Joda DateTime format like yyyy-MM-dd HH:mm:ss.
Syntaxβ
DATETIME str_to_jodatime(VARCHAR str, VARCHAR format)
Parametersβ
str: the time expression you want to convert. It must be of the VARCHAR type.format: the Joda DateTime format of the DATETIME value to be returned. For information about the formats available, see Joda DateTime.
Return valueβ
- If parsing the input string succeeds, a DATETIME value is returned.
- If parsing the input string fails,
NULLis returned.