TO_UNIX_TIMESTAMP (Lakehouse v1)
Convertit un timestamp au format date/heure en timestamp Unix. Un timestamp Unix représente le nombre de secondes écoulées depuis le 1er janvier 1970 à 00:00:00 UTC.
Syntaxe Analyze
Section intitulée « Syntaxe Analyze »func.to_unix_timestamp(<expr>)Exemples Analyze
Section intitulée « Exemples Analyze »func.to_unix_timestamp('2023-11-12 09:38:18.165575')
┌────────────────────────────────────────────────────────────────┐│ func.to_unix_timestamp('2023-11-12 09:38:18.165575') ││ UInt32 │├────────────────────────────────────────────────────────────────┤│ 1699781898 │└────────────────────────────────────────────────────────────────┘Syntaxe SQL
Section intitulée « Syntaxe SQL »TO_UNIX_TIMESTAMP(<expr>)Arguments
Section intitulée « Arguments »| Arguments | Description |
|---|---|
<expr> |
Timestamp |
Pour plus d’informations sur le type de données timestamp, consultez Date & Time.
Type de retour
Section intitulée « Type de retour »BIGINT
Exemples SQL
Section intitulée « Exemples SQL »SELECT to_unix_timestamp('2023-11-12 09:38:18.165575')
┌─────────────────────────────────────────────────┐│ to_unix_timestamp('2023-11-12 09:38:18.165575') ││ UInt32 │├─────────────────────────────────────────────────┤│ 1699781898 │└─────────────────────────────────────────────────┘