UPDATE with ORDER BY

From: "Robins Tharakan" <tharakan(at)gmail(dot)com>
To: pgsql-sql <pgsql-sql(at)postgresql(dot)org>
Subject: UPDATE with ORDER BY
Date: 2008-02-19 12:49:02
Message-ID: 36af4bed0802190449m247ee430ge37bee5acdcb6e13@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Hi,

I know this kind of a question is asked earlier, but I couldn't find an
answer there (in the previous round of posting).

Instead of wanting to update the first record in an UPDATE .. ORDER BY
condition, (because of triggers that act downward) what I want is that all
records be updated, but in a given order, for e.g. ascending on date.

Is a FOR LOOP my best bet or is something like UPDATE .... ORDER BY in the
offing ?

Thanks
*Robins*

Browse pgsql-sql by date

  From Date Subject
Next Message Richard Huxton 2008-02-19 13:48:12 Re: Am I wasting my time with partitions?
Previous Message Stuart Brooks 2008-02-19 10:54:14 Am I wasting my time with partitions?