Created
May 2, 2022 19:08
-
-
Save nfarah86/81aa2cce866ea0b38561d0cc1b588900 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT | |
* | |
, cast(DATE_TRUNC('HOUR', PARSE_TIMESTAMP('%a %h %d %H:%M:%S %z %Y', i.created_at)) as string) as event_date_hour | |
, PARSE_TIMESTAMP('%a %h %d %H:%M:%S %z %Y', i.created_at) as _event_time | |
, cast(i.id as string) as id | |
FROM | |
_input i | |
where | |
i.user.id is not null | |
and i.user.id is not undefined |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment