update ... set ... subquery

From: John Smith <jayzee(dot)smith(at)gmail(dot)com>
To: PostgreSQL General <pgsql-general(at)postgresql(dot)org>
Subject: update ... set ... subquery
Date: 2010-03-17 19:13:26
Message-ID: f029597e1003171213w3d681508l74c2cd993d518d72@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

guys,
trying multiple updates without success like so:

update a
set number = any ( select number from b where a.number=b.number)
where number is null;
>> 'syntax error at or near "any"'

subquery returns more than one row. using 8.1.
thks, jzs

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2010-03-17 19:34:42 Re: building a c function
Previous Message Stuart McGraw 2010-03-17 18:27:50 building a c function