Using "using" on joins leads to wrong "ambiguous reference" errors
rswheeldon opened this issue Β· comments
Richard Wheeldon commented
Describe the bug
Doing a join with "using" for a column ID implies it's not ambiguous - it doesn't matter which one you pick because they're the same. Postgres realizes this but pg-mem doesn't.
column reference "x" is ambiguous
π This seems to be an execution error, which means that your request syntax seems okay,
but the resulting statement cannot be executed β Probably not a pg-mem error.
*οΈβ£ Reconsituted failed SQL statement: SELECT x FROM foo INNER JOIN bar USING (x)
To Reproduce
create table foo(x integer);
create table bar (x integer);
select x from foo join bar using (x);
pg-mem version
2.8.1 (reproducible in playground at time of writing)