Re: UPDATE in a specific order

From: "Luiz K(dot) Matsumura" <luiz(at)planit(dot)com(dot)br>
To: pgsql-sql(at)postgresql(dot)org, jasen(at)xnet(dot)co(dot)nz
Subject: Re: UPDATE in a specific order
Date: 2010-12-17 19:01:46
Message-ID: 4D0BB39A.9040204@planit.com.br
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Thanks for reply,

Em 16/12/2010 17:58, Jasen Betts escreveu:
>> I need to make update of table1 with data on table2 in the order of id
>> of table2
> that looks like EAV. is it?
>

Err, I don´t know so much about EAV, so I think that isn´t. I´m just
trying to reproduce a calc in a spreeadsheet.
>> There are some way to do this with a UPDATE statement ?
> to do it with an update statement you need no more than one rows in the
> from for each row in the target.
>
> easiest non update statement approach is probably to use a plpgsql
> function with a loop.
>
> basically you need to find another way to do it.
>

Ok! I make a function in plpgsql to do it.

Thank´s again !

*
*

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Andrey Fokin 2010-12-18 12:46:38 Table name as a variable in SELECT query
Previous Message acurtis416 2010-12-17 16:58:54 Help with Function in plpgsql