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
 

 

Issue a checkpoint in an IMS program

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

New User


Joined: 31 Jan 2008
Posts: 30
Location: Woodland Hills, CA

PostPosted: Fri Mar 28, 2008 3:26 pm    Post subject: Issue a checkpoint in an IMS program
Reply with quote

Hi

Can anybody help me for the following.

I need to issue a checkpoint in an IMS program for the previous record which is read from a GSAM file.
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Fri Mar 28, 2008 8:48 pm    Post subject:
Reply with quote

Hello,

Please explain why you need to issue a checkpoint after a read.
Back to top
View user's profile Send private message
Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Fri Mar 28, 2008 9:16 pm    Post subject:
Reply with quote

To do checkpoint issue CKPT call in your IMS BMP program.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Fri Mar 28, 2008 10:49 pm    Post subject:
Reply with quote

Hi,

Check point is usually associated with RESTART, is this what your concern is? As asked
Quote:
why you need to issue a checkpoint after a read.
is not a usual scenario, unless I misunderstood.
Back to top
View user's profile Send private message
jithumohan

New User


Joined: 31 Jan 2008
Posts: 30
Location: Woodland Hills, CA

PostPosted: Mon Mar 31, 2008 9:43 am    Post subject:
Reply with quote

Because the program should handle a number of records in the input file at a time.

The program need to be restarted from the last record of the previous group even if it starts reading the next group.
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Mon Mar 31, 2008 7:25 pm    Post subject:
Reply with quote

Hello,

Please do some more research about how checkpoint/restart works or talk with your dba(s).

If i understand your situation, issuing a checkpoint after some number of reads will not cause a re-run to start at the "read" you want.
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Mon Mar 31, 2008 8:14 pm    Post subject:
Reply with quote

Why not take a checkpoint after you read a group of records?
Back to top
View user's profile Send private message
jithumohan

New User


Joined: 31 Jan 2008
Posts: 30
Location: Woodland Hills, CA

PostPosted: Tue Apr 01, 2008 10:32 am    Post subject:
Reply with quote

I will explain the scenario...... icon_smile.gif

Let following are the records in the input file (Lrecl = 4500)
A1, B11, B12, B13, A2, B22, B23, B24, A3..

Suppose the program abended at the record B12. I need to restart the job from the record A1.

Similary if the program abended at B23, it need to be started from A2.

For this I need to issue checkpoint after processing B13 and B24 respectively. Please note that the number of records in a group is not fixed (here the number of B). So we cannot predict whether B13 is the last record in the first group and similarly B24 is the last record in second group.

I suppose now you understood the situation. icon_biggrin.gif
Back to top
View user's profile Send private message
gowtham_1982
Warnings : 1

Active User


Joined: 02 Dec 2005
Posts: 109

PostPosted: Tue Apr 01, 2008 3:58 pm    Post subject:
Reply with quote

jithumohan wrote:
I will explain the scenario...... icon_smile.gif

Let following are the records in the input file (Lrecl = 4500)
A1, B11, B12, B13, A2, B22, B23, B24, A3..

Suppose the program abended at the record B12. I need to restart the job from the record A1.

Similary if the program abended at B23, it need to be started from A2.

For this I need to issue checkpoint after processing B13 and B24 respectively. Please note that the number of records in a group is not fixed (here the number of B). So we cannot predict whether B13 is the last record in the first group and similarly B24 is the last record in second group.

I suppose now you understood the situation. icon_biggrin.gif



can you please try out this logic?

issue a chkp call after reading the first record of every group. hence when you read A2, you can issue a chkp call.. similarly after reading A3, you can issue a chkp call and so on....

the above logic is as per my understanding that, the job has to be restarted from the first record of the group.

please let me know for any queries or correct me if i am incorrect.

kind regards,

gowtham
Back to top
View user's profile Send private message
jithumohan

New User


Joined: 31 Jan 2008
Posts: 30
Location: Woodland Hills, CA

PostPosted: Tue Apr 01, 2008 4:06 pm    Post subject:
Reply with quote

Thanks for the help.. but the issue is still there. Because ur logic is for issuing checkpoint after every 'A' record comes.

I need to issue checkpoint before reading A2, A3 etc... ie just after the processing of B13, B24 etc.

As per ur logic the my requirement will fail. coz we have already read the first record from the next group (ie A records).
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Tue Apr 01, 2008 5:35 pm    Post subject:
Reply with quote

Is this message spullied with each CKPT call? If so you can use the last -/- 1 ID or timestamp to XRST and our suggestion can work.
Back to top
View user's profile Send private message
jithumohan

New User


Joined: 31 Jan 2008
Posts: 30
Location: Woodland Hills, CA

PostPosted: Tue Apr 01, 2008 5:52 pm    Post subject:
Reply with quote

Could you please explain more?
Back to top
View user's profile Send private message
Bitneuker

CICS Moderator


Joined: 07 Nov 2005
Posts: 1105
Location: The Netherlands at Hole 19

PostPosted: Tue Apr 01, 2008 6:08 pm    Post subject:
Reply with quote

After a CKPT call IMS supplies you with a message containing CKPT-ID. After you reach a new group take a checkpoint. If you need to restart do the restart with the CKPT-ID supplied in the message before the last ID. Follow this and explore.
Back to top
View user's profile Send private message
jithumohan

New User


Joined: 31 Jan 2008
Posts: 30
Location: Woodland Hills, CA

PostPosted: Tue Apr 01, 2008 6:13 pm    Post subject:
Reply with quote

"If you need to restart do the restart with the CKPT-ID supplied in the message before the last ID."

Please think what will be the value for last ID here. I think it will be checkpoint issued on 'A' record. Right? In this case same issue will be there that I told you early. We cannot read the record A from the input file after issuing check point even if it is abended at it corresponding B records. Right?
Back to top
View user's profile Send private message
pvaithee

New User


Joined: 20 Jan 2008
Posts: 1
Location: Chennai

PostPosted: Sun Apr 27, 2008 11:59 am    Post subject:
Reply with quote

Hi,

If you are not sure of the last record of the group it is not possible to issue a checkpoint exactly for that record.

But u can do onething, after reading the first record of the next group issue a checkpoint and put the data of the record read in a save area. in case if the job abend now in B23 the pointer will be in A2. Now while restarting, restore the value of the A2 from save area and give a get next call to the GSAM file which will start form the next record i.e B22(in this case). But in this case u cannot skip this group if u need, so always have a bypass logic for the program.

As of my understanding it is not possible to issue check point for the group without reading the next group record.

Thanks...
Back to top
View user's profile Send private message
vijaynagabhairava

New User


Joined: 13 Apr 2008
Posts: 3
Location: India

PostPosted: Sun May 04, 2008 10:18 pm    Post subject: Reply to: Issue a checkpoint in an IMS program
Reply with quote

Hi,

Try the following logic.

"Issue a checkpoint after reading every B record and save the checkpoint ID in a working storage variable. When you encounter an A type record you just display the value in the variable. Now when the program abends, you just restart the program from the last checkpoint ID displayed in the spool".

I believe it will work for you. If you still persisting with the problem please let me know.
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 I can not compile my program PL1 V3.R... Miguel Fernandez PL/I & Assembler 13 Tue Dec 06, 2016 8:30 pm
No new posts IMS BMP program causes 878 system abend Artemk IMS DB/DC 7 Tue Nov 22, 2016 8:26 pm
No new posts DFHRESPONSE returns issue divated CICS 3 Wed Nov 02, 2016 6:32 pm
No new posts Can sending 5 MB data between cobol p... Kevin Vaz CICS 12 Tue Oct 18, 2016 4:50 pm
No new posts A sample of exit program for exit XMN... lind sh CICS 2 Mon Oct 03, 2016 5:07 pm


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