Created
August 29, 2016 01:06
-
-
Save iamedu/7ded1fc8946aa9261fbe0c3bd2ab9069 to your computer and use it in GitHub Desktop.
Postgres start of day in custom timezone
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 to_date(to_char(current_timestamp AT TIME ZONE 'America/Mexico_City', 'YYYY-MM-dd'), 'YYY-MM-DD')::timestamp AT TIME ZONE 'America/Mexico_City'; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment