Subject | Re: [firebird-support] Copy row to row in stored procedure |
---|---|
Author | Valeri Mytinski |
Post date | 2009-03-23T13:04:58Z |
Thanks.
But it is not EASY way:
1) There may be many columns in a table.
2) Columns may be added or deleted in the future.
So maintenance cost of such solution is high,
and code readability is low.
2009/3/23, Nick Upson <nick.upson@...>:
But it is not EASY way:
1) There may be many columns in a table.
2) Columns may be added or deleted in the future.
So maintenance cost of such solution is high,
and code readability is low.
2009/3/23, Nick Upson <nick.upson@...>:
> insert into tablea (col1, col2, ...) select col1, col2, ... from tablea
> where
>
> 2009/3/23 Valeri Mytinski <valeri.mytinski@...>:
>> I have to copy one (existing) row to another (new) row in the same
>> table within stored procedure.
>> 3 steps needed as I see:
>>
>> 1. Fetch whole row into "record-like" variable or something else.
>> 2. Change PK in "variable".
>> 3. Insert new row with values from "variable".
>>
>> Do you know easy way(s) for this? Or may be special tools for this exists
>> in FB?
>>
>>
>> ------------------------------------
>>
>> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>>
>> Visit http://www.firebirdsql.org and click the Resources item
>> on the main (top) menu. Try Knowledgebase and FAQ links !
>>
>> Also search the knowledgebases at http://www.ibphoenix.com
>>
>> ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
>> Yahoo! Groups Links
>>
>>
>>
>>
>