Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Forum Index
 
Register
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Checkpoint & Restart logic

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC
View previous topic :: :: View next topic  
Author Message
sunnybunny

New User


Joined: 29 Nov 2005
Posts: 49

PostPosted: Tue Jul 17, 2007 5:15 pm    Post subject: Checkpoint & Restart logic
Reply with quote

Hello Friends,

Could you anyone help me on the below.

My requirement is, I have two sorted input files. From the first file I am reading the first record with one key. By taking that key as input I am reading the second file to get all the records which are equal to that key.
After reading corresponding records from second file based on some validations iam doing the update and delete operations in a DB2 table.
Next I will read second record from first file and then I will follow the same process which I have explained above.

Hence this is a IMS/DB2 program, I should use restart and check point logic for this. I have used checkpoint in the following scenarios.
1. After every record read from the first file
2. After Deleting the key from table
3. After Updating some other key from table
I am incrementing the Checkpoint field.

And finally I am calling the Check point call for every 500 records of first file.

Now my concern is that, as I mentioned above I am putting the check point frequency as 500 and Iam calling the checkpoint call after 500 reads of first file.

Let us I have deleted the record from database as below.
1. At 800 record
2. At 810 record
3. At 830 record abended.

So now as per my logic program will restart from 501th record and the records 800, 810 are already deleted. So this will gives problem.

Please let us know how to handle this.

Regards,
Sunny.
Back to top
View user's profile Send private message

William Thompson

Global Moderator


Joined: 18 Nov 2006
Posts: 3158
Location: Tucson AZ

PostPosted: Tue Jul 17, 2007 5:36 pm    Post subject:
Reply with quote

????????????
If the only checkpoint you have taken (at the time of the abend at record 830) is at record 500, the deletion of records 800 and 810 would have been rolled back and the will need to be deleted again.
Back to top
View user's profile Send private message
scdinesh
Warnings : 1

New User


Joined: 06 Sep 2006
Posts: 40
Location: United States

PostPosted: Tue Jul 17, 2007 6:10 pm    Post subject: Re: Checkpoint & Restart logic
Reply with quote

Friend,

Do u issuing checkpoint calls on regardance with file ?
If file then is it flat file or GSAM file?
In flat file checkpoint logic wont work properly....But if it is GSAM file then
go for checkpoint logic with Rolb call (if necessary), also give backout in the jcl..

Thanks,
S.Dinesh
Back to top
View user's profile Send private message
sunnybunny

New User


Joined: 29 Nov 2005
Posts: 49

PostPosted: Wed Jul 18, 2007 11:49 am    Post subject:
Reply with quote

HI,

Thanks for your information.

Regards,
Sunny.
Back to top
View user's profile Send private message
enrico-sorichetti

Senior Member


Joined: 14 Mar 2007
Posts: 10632
Location: italy

PostPosted: Wed Jul 18, 2007 11:59 am    Post subject: Re: Checkpoint & Restart logic
Reply with quote

Quote:
So now as per my logic program will restart from 501th record and the records 800, 810 are already deleted. So this will gives problem.


checkpoint restart logic SHOULD be single event driven ONLY.

The only reasonable way to do it is to let it be drivent by a read frequency/threshold.

in this way all the updates/deletes will be consistent when related to the input flow.

I would for example ( given the usual if's ) load the first file to a db2 table,
delete each row as soon as the relevant processing has been done.
checkpointing on a chosen frequency.

in case of abend the system will take care of rollbacks and You could simply resubmit the job

regards


e.s
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> IMS DB/DC All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Do we need to restart DB2 Z/OS for DA... Hooman24 DB2 0 Sat Sep 21, 2019 12:27 pm
This topic is locked: you cannot edit posts or make replies. Compare two files logic in COBOL Nishant Singhal COBOL Programming 4 Sun Aug 25, 2019 2:25 am
No new posts use daylight logic in REXX maxsubrat CLIST & REXX 1 Wed Jan 30, 2019 5:08 pm
No new posts IMS BMP Checkpoint Overhead Hooman24 IMS DB/DC 6 Sun Nov 25, 2018 10:19 pm
No new posts Removing the period or dot from the v... gopinak COBOL Programming 6 Wed May 09, 2018 1:53 pm

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us