On 6 Jul 2010, at 13:03, Andre Lopes wrote: > Hi Alban, > > But in my application I have more than one way of uniquely identify the record. Could be by the email field or by the id field. Unique is unique. There is no other record that could possibly be identified by the same unique identifier. It doesn't matter if you can identify the same record using other identifiers that are also unique, it's still a unique identifier. So if you have a unique identifier for your table you can use on the OLD row in the WHERE clause. For example, if you have a primary key on that table you can use it to identify the records for the update. Whether that PK uses a simple unique index or a composite unique index doesn't matter at all either. Alban Hertroys -- Screwing up is an excellent way to attach something to the ceiling. !DSPAM:737,4c33391e286211703874864! -- Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-general