Bill Moran wrote: > Is it possible that your UPDATE command is updating multiple rows? I > don't believe RETURNING will work on an UPDATE that touches more than 1 > row. Hmm, why not? alvherre=> create table bill (a int, b text); CREATE TABLE alvherre=> insert into bill values (1, 'one'); INSERT 0 1 alvherre=> insert into bill values (2, 'two'); INSERT 0 1 alvherre=> update bill set b = a || ' ' || b returning b; b ------- 1 one 2 two (2 lignes) UPDATE 2 -- Alvaro Herrera http://www.CommandPrompt.com/ PostgreSQL Replication, Consulting, Custom Development, 24x7 support