Describe the bug
I filed #2201 with a minimum repro, which you were able to fix (thank you!) but AT TIME ZONE is still failing in the way we're using it.
Database Engine
PostgreSQL
To Reproduce
First off, select start_time AT time zone 'UTC' as start_time from my_table succeeds but select start_time at time zone 'UTC' as start_time from my_table fails. It appears the AT is case sensitive.
Secondly, using a variable instead of a literal fails:
select start_time at time zone loc.timezone as start_time from my_table
Here is a more complicated version we would also expect to parse:
select date(cast(t.start_time at time zone loc.timezone as timestamptz)) as start_time from my_table t
Expected behavior
All three examples should parse as they are valid sql.
Describe the bug I filed #2201 with a minimum repro, which you were able to fix (thank you!) but AT TIME ZONE is still failing in the way we're using it.
Database Engine PostgreSQL
To Reproduce First off,
select start_time AT time zone 'UTC' as start_time from my_table
succeeds butselect start_time at time zone 'UTC' as start_time from my_table
fails. It appears theAT
is case sensitive.Secondly, using a variable instead of a literal fails:
select start_time at time zone loc.timezone as start_time from my_table
Here is a more complicated version we would also expect to parse:
select date(cast(t.start_time at time zone loc.timezone as timestamptz)) as start_time from my_table t
Expected behavior All three examples should parse as they are valid sql.
Additional context 5.3.4