Re: Putting an aggregate value in an UPDATE statement...

Поиск
Список
Период
Сортировка
От Leif Biberg Kristensen
Тема Re: Putting an aggregate value in an UPDATE statement...
Дата
Msg-id 201006012343.32625.leif@solumslekt.org
обсуждение исходный текст
Ответ на Re: Putting an aggregate value in an UPDATE statement...  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Putting an aggregate value in an UPDATE statement...  (John Gage <jsmgage@numericable.fr>)
Список pgsql-novice
On Tuesday 1. June 2010 23.34.39 Tom Lane wrote:
> Well, the main point is that the possible ambiguity means that SQL has
> mandated you put parentheses around any sub-select.  However, if you're
> claiming there is no possible ambiguity inside a function call, compare:
>
>     select myfunc((select integer_col from foo where bar = 5+4))
>     select myfunc((select integer_col from foo where bar = 5)+4)
>
> These mean different things, and you couldn't tell 'em apart without
> the inner parentheses.

Right, I get it. Thanks for the explanation.

regards,
--
Leif Biberg Kristensen
http://solumslekt.org/blog/

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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Putting an aggregate value in an UPDATE statement...
Следующее
От: Michelle Konzack
Дата:
Сообщение: Re: Invitation to connect on LinkedIn