second
function
Applies to: Databricks SQL Databricks Runtime
Returns the second component of the timestamp in expr
.
second(expr)
expr
: ATIMESTAMP
expression.
An INTEGER
.
This function is equivalent to int(extract(SECOND FROM timestamp))
.
> SELECT second('2009-07-30 12:58:59');
59