Apache Hive : HPL/SQL - UNIX_TIMESTAMP Function

Last updated: August 12, 2026

Apache Hive : HPL/SQL - UNIX_TIMESTAMP Function

UNIX_TIMESTAMP function returns the current date and time in seconds since 1970-01-01 00:00:00.

Syntax:

UNIX_TIMESTAMP()

Return Type:

INT

Example:

Get the current and date and time in seconds:

UNIX_TIMESTAMP()
--
1446631617

Compatibility: Hive.

See also: