View previous topic :: View next topic
|
Author |
Message |
rhutwik
New User
Joined: 03 Apr 2007 Posts: 5 Location: Pune
|
|
|
|
hi all
Please let me know the answer if anyone knows it ...
suppose we are updatiing rows of a db2 table corresponding to value of the key which is supplied from the i/p file.
suppose after updating first 10000 records program abends or stop working. then how can we restart the processing after the last updated record. |
|
Back to top |
|
|
guptae
Moderator
Joined: 14 Oct 2005 Posts: 1208 Location: Bangalore,India
|
|
|
|
Hi There,
Use checkponit restart logic in ur program & after every checkpoint put an explicit COMMIT |
|
Back to top |
|
|
rhutwik
New User
Joined: 03 Apr 2007 Posts: 5 Location: Pune
|
|
|
|
can you please give me some pointers for this logic ... imean from where i can get this kind of info?? |
|
Back to top |
|
|
ashwinreddy
Active User
Joined: 16 Sep 2004 Posts: 106 Location: Hyderabad
|
|
|
|
Hi,
Commit/restart capability within a batch application program.
A checkpoint routine will record the status of an executing application program, store the contents of specified program variables, note the position into sequential files, and issue a DB2 COMMIT. If the application program ends abnormally, the status of the program at the last checkpoint will be retained. Upon the restart of the application program, we can recall the last checkpoint information.
We used to use a Checkpoint table where the columns are Program name, Tables Keys, commit frequency and Interval.
I think this mightn't be the case with your application.
Please correct me if i am wrong.
Cheers
Ashwin |
|
Back to top |
|
|
rhutwik
New User
Joined: 03 Apr 2007 Posts: 5 Location: Pune
|
|
|
|
Thanks a lto ......i got your point ..... it is what i wanted but can u pleeeeeeeeeeeeeeeeeeeeese give some pointer so that i can understand this concept in depth ...... Thanks in advance |
|
Back to top |
|
|
khamarutheen
Active Member
Joined: 23 Aug 2005 Posts: 677 Location: NJ
|
|
|
|
Hi,
Use the JCL for Creating Checkpoint as
Code: |
//CHECKPT DD DSNAME=CHECK1,
// UNIT=SYSDA,SPACE=(subparms),
// DISP=({NEW|MOD},PASS,KEEP) |
In COBOL define it in ENVIRONMENT DIVISION.
Code: |
RERUN ON CHEKPT EVERY
10000 RECORDS OF FILENAME. |
|
|
Back to top |
|
|
rhutwik
New User
Joined: 03 Apr 2007 Posts: 5 Location: Pune
|
|
|
|
thanks a ton |
|
Back to top |
|
|
|