Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups 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: 37
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

Global Moderator


Joined: 14 Mar 2007
Posts: 10256
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 Need help in building a logic Benchwarmer All Other Mainframe Topics 4 Wed Feb 22, 2017 2:49 am
No new posts Need points to tune IMS Checkpoint Pr... satish.ms10 IMS DB/DC 2 Fri Sep 30, 2016 4:12 pm
No new posts Wildcard logic in COBOL dudenithy COBOL Programming 13 Thu Sep 01, 2016 7:36 pm
No new posts Sort Logic to extract data scorp_rahul23 DFSORT/ICETOOL 13 Tue Mar 01, 2016 1:22 am
No new posts Need a logic to validate the data in ... sandeep kumar302 COBOL Programming 17 Mon Feb 01, 2016 3:30 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us