View previous topic :: View next topic
|
Author |
Message |
krk_kumar1
New User
Joined: 14 Mar 2006 Posts: 39
|
|
|
|
Hi,
I 'am using DSNUPROC to load data into Db2 tables.i have a following scenario.
Initially TableA had 50 rows then I loaded 50 rows. so totally now i have 100 rows in TableA. Now i want to replace the 50 rows what ever i've loaded with the new set of data other than primary key.
I went through replace option but it will replace the entire set of 100 rows with the 50 rows whatever i loaded. Is there anyway to replace the 50 rows whatever i've loaded leaving the rest of the 50 rows intact.
Thanks in advance. |
|
Back to top |
|
|
ravi17s Warnings : 1 New User
Joined: 15 Aug 2003 Posts: 57
|
|
|
|
Krishna,
1. Unload the entire table first
2. Load the new data with REPLACE
3. Now LOAD the data wihich you have UNLOADED(SYSREC) with DISCARD OPTION.
The duplicates rows will be discarded automatically and only those First 50 rows will be loaded.But LAST_MODIFIED_DTM and CREATE DTM differs.
Hanfur please help me in solving Krishna's Requirement.Wat do you think?
Thanks,
Ravi... |
|
Back to top |
|
|
krk_kumar1
New User
Joined: 14 Mar 2006 Posts: 39
|
|
|
|
Thanks for u'r quick response Ravi.I told that table has 50 rows as example but the table actually has arround 700 million rows and i'am trying to update nearly 10 million rows.unloading all and loading them again will be a tedious task and will take more time as well. Is it possible by any chance to replace those 50 rows alone other than writting any program. |
|
Back to top |
|
|
|