Subject | Re: [firebird-support] using sql to update record individually |
---|---|
Author | Helen Borrie |
Post date | 2003-07-26T04:17:12Z |
At 02:54 AM 26/07/2003 +0000, you wrote:
be quicker).
update invoicedetails id
set id.unit2 = (select i1.unit2 from items i1 where i1.itemid = id.itemid),
id.conversion = (select i2.conversion from items i2 where i2.itemid =
id.itemid) ;
heLen
>using sql to update record individuallyYes, using correlated subqueries in two cursors, but it's slow. (SP would
>
>I have 2 table one is items and the other is invoicedetails
>
>recently I have added an additional field to the invoicedetails,
>which a UNIT2 and CONVERSION. This 2 fields exists on the items
>table. Since the field UNIT2 and conversion is just recently added, I
>want to fill those null fields with values from the items table.
>
>Is there a sql statement to do this job? But not using stored
>procedures.
be quicker).
update invoicedetails id
set id.unit2 = (select i1.unit2 from items i1 where i1.itemid = id.itemid),
id.conversion = (select i2.conversion from items i2 where i2.itemid =
id.itemid) ;
heLen
>thanks.
>
>
>
>To unsubscribe from this group, send an email to:
>firebird-support-unsubscribe@yahoogroups.com
>
>
>
>Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/