RE: [HACKERS] SELECT ... AS ... names in WHERE/GROUP BY/HAVING

Поиск
Список
Период
Сортировка
От Ansley, Michael
Тема RE: [HACKERS] SELECT ... AS ... names in WHERE/GROUP BY/HAVING
Дата
Msg-id 1BF7C7482189D211B03F00805F8527F748C35C@S-NATH-EXCH2
обсуждение исходный текст
Список pgsql-hackers
Yes, you are right, of course, it doesn't mean that it's incorrect.
However, assuming that Oracle adheres strictly to the standard (which is a
good, but not infallible, assumption), it means that we don't.  Of course,
we may just extend the standard, but in this particular area, I'm not sure
that it's a good idea, because it can be very confusing, and lead to
inadvertent mistakes, which can be very difficult to find.

MikeA

-----Original Message-----
From: Zeugswetter Andreas SB
To: 'Ansley, Michael'; 'pgsql-hackers@postgreSQL.org '
Sent: 99/12/16 06:22
Subject: AW: [HACKERS] SELECT ... AS ... names in WHERE/GROUP BY/HAVING


> So, according to Oracle's view of the world, HAVING is orrect 
> because it
> rejects aliases, but GROUP BY is broken because it accepts them.

Just because it is more powerful than the standard does not mean it is
broken.
The only thing, that is broken is that the alias is taken before the
colname,
and thus results in wrong output for a standard conformant query.

Andreas


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] NOTICE: LockRelease: locktable lookup failed, no lock
Следующее
От: wieck@debis.com (Jan Wieck)
Дата:
Сообщение: Prepared for LONG