You are viewing an older version of this section. View current production version.
Join the MemSQL Community Today
Get expert advice, develop skills, and connect with others.

TIMESTAMP

Convert the input argument to a datetime object.

Syntax

TIMESTAMP(dateobj)

Arguments

  • dateobj: a valid date, datetime, or parsable date string.

Return Type

Datetime object. If dateobj is not a valid date, returns NULL.

Examples

memsql> select timestamp('2015-03-03');
+-------------------------+
| timestamp('2015-03-03') |
+-------------------------+
| 2015-03-03 00:00:00     |
+-------------------------+

Related Topics