GSAM file shows more records after abend.

RDBMS from IBM and IBM's Hierarchical DBMS and Transaction Manager (IMS DC).
Post Reply
Shriram
Registered Member
Posts: 21
Joined: Fri Aug 16, 2013 3:13 pm

GSAM file shows more records after abend.

Post by Shriram »

Hi
Iam running an IMS DB program with check-point restart logic in it. The Job abended after 588th record. Check-point is issued after 100 records. Output file is a GSAM file. I was expecting that my output file to have only 500 records but I don't know why it shows 588 records! Why this happnes? Why all the records are written to the output and not just 500?
nicc
Global Moderator
Global Moderator
Posts: 691
Joined: Wed Apr 23, 2014 8:45 pm

Re: GSAM file shows more records after abend.

Post by nicc »

Perhaps your coding is wrong.
Regards
Nic
User avatar
Anuj Dhawan
Founder
Posts: 2799
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: GSAM file shows more records after abend.

Post by Anuj Dhawan »

"It's working as designed"! :)

With Check-point restart all the records which are processed successfully will be written to the output however, when you restart the program will start processing from 501[sup]st[/sup] record.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
Shriram
Registered Member
Posts: 21
Joined: Fri Aug 16, 2013 3:13 pm

Re: GSAM file shows more records after abend.

Post by Shriram »

But then how about those 88 records?? What will happen to them?
User avatar
Anuj Dhawan
Founder
Posts: 2799
Joined: Sun Apr 21, 2013 7:40 pm
Location: Mumbai, India
Contact:
India

Re: GSAM file shows more records after abend.

Post by Anuj Dhawan »

They are processed again from the input and written to output. In the case of abend you are not sure about the integrity of the data and you restart from the last successful execution even if it means processing some records again, but you know all is working as you intended it to.
Thanks,
Anuj

Disclaimer: My comments on this website are my own and do not represent the opinions or suggestions of any other person or business entity, in any way.
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 825
Joined: Wed Sep 11, 2013 3:57 pm

Re: GSAM file shows more records after abend.

Post by enrico-sorichetti »

GSAM files will be in an unpredictable state until ALL the IMS recovery actions have been done.
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)
Shriram
Registered Member
Posts: 21
Joined: Fri Aug 16, 2013 3:13 pm

Re: GSAM file shows more records after abend.

Post by Shriram »

enrico-sorichetti wrote:GSAM files will be in an unpredictable state until ALL the IMS recovery actions have been done.
You mean this is the rason that i see those extra records?
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 825
Joined: Wed Sep 11, 2013 3:57 pm

Re: GSAM file shows more records after abend.

Post by enrico-sorichetti »

You mean this is the rason that i see those extra records?
yes.
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)
Shriram
Registered Member
Posts: 21
Joined: Fri Aug 16, 2013 3:13 pm

Re: GSAM file shows more records after abend.

Post by Shriram »

Now because the abend has happened so the GSAM is in unpredictable state. But then such unpredictable state does not come that's why we write check-point restart logic. If it's not being taken care then what's the benefit of the check-point restart in the program?
enrico-sorichetti
Global Moderator
Global Moderator
Posts: 825
Joined: Wed Sep 11, 2013 3:57 pm

Re: GSAM file shows more records after abend.

Post by enrico-sorichetti »

If it's not being taken care
IMS has all the things in place to provide data integrity and consistency across failures

If You do nothing DBs state will be unpredictable

If, on the other side,
You , Your operations, Your support, Your whatever f****** name You call it do what the IBM manuals tell to do

the data bases will be updated only once, the input GSAM DB records will be processed only once, the output GSAM DB will not contain any duplicate records.


it is almost time to lock the topic :evil:
cheers
enrico
When I tell somebody to RTFM or STFW I usually have the page open in another tab/window of my browser,
so that I am sure that the information requested can be reached with a very small effort 8-)
Shriram
Registered Member
Posts: 21
Joined: Fri Aug 16, 2013 3:13 pm

Re: GSAM file shows more records after abend.

Post by Shriram »

Thanks!
Post Reply

Create an account or sign in to join the discussion

You need to be a member in order to post a reply

Create an account

Not a member? register to join our community
Members can start their own topics & subscribe to topics
It’s free and only takes a minute

Register

Sign in

Return to “IBM DB2 and IMS DB/DC”