Re: GROUP BY column alias? - Mailing list pgsql-general

From Eric B. Ridge
Subject Re: GROUP BY column alias?
Date
Msg-id 2D59EF5A-09C5-4ED3-B851-B1C9FCB50923@tcdi.com
Whole thread Raw
In response to Re: GROUP BY column alias?  (Scott Bailey <artacus@comcast.net>)
Responses Re: GROUP BY column alias?  (Lew <noone@lwsc.ehost-services.com>)
List pgsql-general
On Feb 18, 2010, at 5:52 PM, Scott Bailey wrote:

> SQL name resolution rules are that column names have higher precedence than aliases and variables. So it will always
bindto the column not the alias. 

That explains it.  Thanks.  Breaks the rule of least surprise, but it is SQL.

eric

pgsql-general by date:

Previous
From: Scott Bailey
Date:
Subject: Re: GROUP BY column alias?
Next
From: Tatsuo Ishii
Date:
Subject: Re: pgpool error, pid not found!