Re: update with from

Поиск
Список
Период
Сортировка
От Alban Hertroys
Тема Re: update with from
Дата
Msg-id CAF-3MvO1G8OsRu+FFRmmFZZmXgVud7NvrEfs+8XhmteB+KFRnA@mail.gmail.com
обсуждение исходный текст
Ответ на Re: update with from  (Sim Zacks <sim@compulab.co.il>)
Ответы Re: update with from  (Sim Zacks <sim@compulab.co.il>)
Список pgsql-general
On 23 January 2012 14:48, Sim Zacks <sim@compulab.co.il> wrote:
>> In my tests, if the joined rows are sorted it always updates with the
>> first row. Does anyone have any other experiences, or should I be
>> concerned that at some point it will behave differently?
>
> I checked my tests again. It always uses the last one, not the first one.
>
> Sim

I expect that your records get updated multiple times too.

Perhaps you can use DISTINCT ON in your from-based UPDATE?

--
If you can't see the forest for the trees,
Cut the trees and you'll see there is no forest.

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

Предыдущее
От: Stuart Bishop
Дата:
Сообщение: Re: Is Synchronous Postgresql Replication Slower Than Asynchronous?
Следующее
От: Simon Riggs
Дата:
Сообщение: Re: Is Synchronous Postgresql Replication Slower Than Asynchronous?