IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Cobol interview Questions


IBM Mainframe Forums -> Mainframe Interview Questions
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
anandinmainframe

Active User


Joined: 31 May 2007
Posts: 171
Location: India

PostPosted: Wed Jan 21, 2009 6:26 pm
Reply with quote

Hi All,
Q1) There is a master file(PS) A and we have two more PS files B & C which has the updated records which is a part of A(Master file), Basically we have to match the records in A with B & C and update the records in master file(A). how can we do that?

Q2) I am writing some records through a cursor into a PS file at some point for some reason the programe is getting abend or stopped at 1000th record. now how can i start from the 1001th record and continue the process.

Note: These questions were asked in an interview, i dont know the answers thats the reason i am posting here.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Wed Jan 21, 2009 9:18 pm
Reply with quote

Hello,

1. Either write a 3-file match/update or first combine the 2 transaction files into one and then do a 2-file match/update to update fileA.

2. The program would need to include restart logic. Places that still perform this type of restart already have a methodology in place and whatever it is, that methodology should be used. Implementing restart logic is less and less common due to the speed of the new cpus and dasd as well as the complexity of managing the restart in a large integrated environment. It is usually faster and cleaner to restart from the beginning of a process than try to continue from some point "in the middle".
Back to top
View user's profile Send private message
rajulan

New User


Joined: 11 Jan 2008
Posts: 66
Location: India

PostPosted: Thu Jan 22, 2009 3:15 pm
Reply with quote

For Db2 restart Logic. you can check the below links.

www.ibmmainframes.com/about7691.html

www.ibmmainframes.com/about1686.html

If u search the forum topics, u will be able to get more info you need.

Thanks,
Rajulan.
Back to top
View user's profile Send private message
lohithegde

New User


Joined: 18 May 2008
Posts: 31
Location: Chennai

PostPosted: Thu Jan 22, 2009 4:53 pm
Reply with quote

Hi i think you are using Cobol as Programing Lang
Q1) Merge both B and C and then use matching logic
Dont forget to use Sort step before that
Q2) Restart logic should be used...Normaly we use Restart logic for programs involves Databse operation
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> Mainframe Interview Questions

 


Similar Topics
Topic Forum Replies
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
No new posts Calling DFSORT from Cobol, using OUTF... DFSORT/ICETOOL 5
No new posts Generate random number from range of ... COBOL Programming 3
Search our Forums:

Back to Top