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
 

 

SRRCMIT concept for MQ

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
kunal jain

New User


Joined: 19 May 2011
Posts: 59
Location: India

PostPosted: Mon Mar 19, 2012 1:20 pm    Post subject: SRRCMIT concept for MQ
Reply with quote

Hi,
I have to code a COBOL Program to fetch the records from a DB2 table.
Every fetched record needs to be inserted to another Db2 Table & also be written to MQ.
I am thinking to have Commit/Restart Logic.
Please let me know the way i can achieve this
Back to top
View user's profile Send private message

dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Mar 19, 2012 2:38 pm    Post subject:
Reply with quote

are you speaking of Batch or CICS?

have you bothered to read anything about RRSAF?

RRS
Back to top
View user's profile Send private message
kunal jain

New User


Joined: 19 May 2011
Posts: 59
Location: India

PostPosted: Mon Mar 19, 2012 3:04 pm    Post subject:
Reply with quote

Its a Batch program. Also The records in MQ are set to trigger task once the MQ has record.
Actually my program has both Db2 Insert & MQPUT.
So need ur suggestion in inluding Commit/Restart logic in my program.
I believe that only issuing MQPUT command will not write a record to MQ unless SRRCMIT is issued or that paritcular program(unit of work) has ompleted. Pls confirm if my understanding is correct.
Back to top
View user's profile Send private message
kunal jain

New User


Joined: 19 May 2011
Posts: 59
Location: India

PostPosted: Mon Mar 19, 2012 4:17 pm    Post subject:
Reply with quote

I would like to rephrase my question on SRRCMIT:
At what instance a Record is actually being written to a MQ from a batch program?
I believe its only after SRRCMIT or when the program completes successfully.
Please confirm
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Mar 19, 2012 5:03 pm    Post subject:
Reply with quote

as db2 has rows not records
mqs has messages not records,
files only have records......

the message is not available to other tasks until
an explicit commit
or
a successful end of task with only an implicit commit.

if you issue an explicit commit (and receive an error free return)
and afterwards your program abends, the messages will still be available to other tasks.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Mon Mar 19, 2012 5:33 pm    Post subject:
Reply with quote

can not say it better than this

and here is another manual concerning rrs
Back to top
View user's profile Send private message
kunal jain

New User


Joined: 19 May 2011
Posts: 59
Location: India

PostPosted: Mon Mar 19, 2012 5:51 pm    Post subject:
Reply with quote

Thanks..my thinking was correct!
Thank you so much for the information & help!!

Much Appreciated
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts JCL overriding concept s.saranya srinivasan JCL & VSAM 14 Wed Oct 07, 2015 4:07 pm
No new posts Image copy concept sravz chinnu DB2 6 Thu Apr 19, 2012 5:10 pm
No new posts Is the concept of Tracker site availa... dejunzhu DB2 1 Sun Apr 10, 2011 4:27 pm
No new posts The Concept of "IT"? superk General Talk & Fun Stuff 5 Wed Dec 01, 2010 10:52 pm
No new posts Concept clarification only - Cobol Db... arien DB2 9 Fri Oct 08, 2010 12:13 am


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