View previous topic :: View next topic |
Author |
Message |
yadav2005 Intermediate

Joined: 10 Jan 2005 Posts: 348 Topics: 144
|
Posted: Tue Feb 20, 2007 8:49 pm Post subject: how to handle load in case of an abend |
|
|
I have a requirement in which i have created a new db2 table in step1.Step2 executes a program which will generate a file and in step3 i am going to load records to the newly created db2 table from the file.
I am new to LOAD utility.If my job abends in step3 while loading records,my understanding is that it will load records to the new table and will abend and my understanding is whatever the records are loaded will remain as it is in the table and rest failed ones will not be loaded and we have to restart again for the abended records.Now to make the job run i have to restart from the step3 in that case how to handle the loading of already existing records.
Please help me in the code which will take of proper load in all conditions.If i am wrong in my understanding please correct me.Thanks. |
|
Back to top |
|
 |
CZerfas Intermediate
Joined: 31 Jan 2003 Posts: 211 Topics: 8
|
Posted: Wed Feb 21, 2007 5:16 am Post subject: |
|
|
If your load runs with the REPLACE option, it does what you want:
It throws away the underlying VSAM dataset, creates a new one and loads the records of the input file. Any probably existing rows in the involved table are thrown away.
That makes life easier in case of a restart situation. Restarting is only becoming complicate if you load additional rows via the RESUME YES option.
regards
Christian |
|
Back to top |
|
 |
|
|