Re: group by can use alias from select list but not the having clause - Mailing list pgsql-bugs

From David G. Johnston
Subject Re: group by can use alias from select list but not the having clause
Date
Msg-id CAKFQuwZ3c4gqSFPXTLFDqQpe0roWQtq0Gt4_6noNgAa2bUbqqQ@mail.gmail.com
Whole thread Raw
List pgsql-bugs
On Monday, July 3, 2023, hape Hape <postgres-hape@gmx.de> wrote:


a) the group by also doesn't know about otto



The isn’t a bug as we explicitly document our deviation from the standard for group by.  You are correct that you are better off not using output column aliases in the group by specification. But we are not going to make doing so,an error and break countless applications relying upon the documented behavior.  But we are also not going to double-down and allow the undesirable deviation for having.

David J.

pgsql-bugs by date:

Previous
From: hubert depesz lubaczewski
Date:
Subject: Re: Backend handling replication slot stuck using 100% cpu, unkillable
Next
From: liu zhilong
Date:
Subject: 回复: BUG #18011: Declarative partition privilege problem cause incorrect execution plans