Mq Error 2042
Post - 2008-05-29T09:38:35Z by SystemAdmin Display:ConversationsBy Date 1-6 of 6 Previous Next SystemAdmin 110000D4XK 8523 Posts Pinned topic Error 2042 2005-05-31T17:56:13Z | Tags: Answered question This question completion code 2, reason 2042 has been answered. Unanswered question This question has not been answered mqrc 2042 yet. Hej I´m new to MQ, and working on a MQ connection from Lotus Domino via Java. I have the basic stuff ready (putting and getting routines), and is now working on error handling. If, for some reason, a get or put routine terminates abnormally, it seems that some kind of connection is kept to the Queue Manager, and I get the error 2042 "Object already in use...."? How do I solve this? Thanks in advance. Rigmor Log in to reply. Updated on 2008-05-29T09:38:35Z at 2008-05-29T09:38:35Z by SystemAdmin SystemAdmin 110000D4XK 8523 Posts Re: Error 2042 2005-05-31T18:44:46Z This is the accepted answer. This is the accepted answer. Catch the exception and close the connection. -joe anniravn@hotmail.com wrote: > Hej > > I´m new to MQ, and working on a MQ connection from Lotus Domino via Java. > > I have the basic stuff ready (putting and getting routines), and is now working on error handling. > > If, for some reason, a get or put routine terminates abnormally, it seems that some kind of connection is kept to the Queue Manager, and I get the error 2042 "Object already in use...."? > > How do I solve this? > > Thanks in advance. > > Rigmor > Log in to reply. SystemAdmin 110000D4XK 8523 Posts Re: Error 2042 2005-05-31T19:11:39Z This is the accepted answer. This is the accepted answer. SystemAdmin 110000D4XK 2005-05-31T18:44:46Z Catch the exception and close the connection. -joe anniravn@hotmail.com wrote: > Hej > > I´m new to MQ, and working on a MQ connection from Lotus Domino via Java. > > I have the basic stuff ready (putti
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support
MQSeries.net Forum Index » General IBM MQ Support » reason code 2042 reason code 2042 « View previous topic :: View next topic » Author Message chris boehnke Posted: Mon Nov 09, 2009 11:45 am Post subject: reason code 2042 PartisanJoined: 25 Jul 2006Posts: https://www.ibm.com/developerworks/community/forums/thread.jspa?threadID=82506 369 Hi Guys, We have our application getting messages from a Mainframe queue manager. When they try getting messages they are getting 2042 reason code. I checked the MQ Options and found that application is using MQOO_INPUT_SHARED. I am not sure what else is causing this error. MQ version 6.0.2.0, z/OS can you guys throw some light on this. Back http://www.mqseries.net/phpBB/viewtopic.php?t=51507&sid=87a0b9bc58377071bd4f1327cd8caecb to top Vitor Posted: Mon Nov 09, 2009 12:17 pm Post subject: Re: reason code 2042 Grand High PoobahJoined: 11 Nov 2005Posts: 23698Location: Ohio, USA chris boehnke wrote: I checked the MQ Options and found that application is using MQOO_INPUT_SHARED. I am not sure what else is causing this error. Another application using input exclusive? (Though frankly I'd have expected a different reason code for that). Something else accessing the queue? Have you checked the queue or just the application that's supposed to be using the queue?_________________Honesty is the best policy. Insanity is the best defence. Back to top chris boehnke Posted: Mon Nov 09, 2009 12:54 pm Post subject: Re: reason code 2042 PartisanJoined: 25 Jul 2006Posts: 369 Vitor wrote: chris boehnke wrote: I checked the MQ Options and found that application is using MQOO_INPUT_SHARED. I am not sure what else is causing this error. Another application using input exclusive? (Though frankly I'd have expected a different reason code for that). Something else accessing the queue? Have you checked the queue or just the application that's suphere for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss http://stackoverflow.com/questions/13965468/ibm-websphere-mq-2042-error the workings and policies of this site About Us Learn more about http://www.ibmmainframeforum.com/websphere/topic7456.html Stack Overflow the company Business Learn more about hiring developers or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community of 6.2 million programmers, just like you, helping each mq error other. Join them; it only takes a minute: Sign up IBM WebSphere MQ 2042 error up vote 1 down vote favorite I have the following code: int openOptions = MQC.MQOO_INQUIRE + MQC.MQOO_FAIL_IF_QUIESCING + MQC.MQOO_INPUT_SHARED; Which when executed, I am getting an error: com.ibm.mq.MQException: MQJE001: Completion Code 2, Reason 2042 MQJE001: Completion Code 2, Reason 2042 This happens while connecting mq error 2042 my Java program with WebSphere MQ. Please note that the queue property is set as input shared. All help appreciated. java websphere-mq share|improve this question edited Dec 20 '12 at 4:56 Perception 55.4k7103136 asked Dec 20 '12 at 4:44 abhinav 2216 add a comment| 1 Answer 1 active oldest votes up vote 2 down vote accepted Although the queue may be set to DEFSOPT(SHARED), this is only a default. It does not prevent a program from opening it with exclusive use. In particular, transmission queues for non-cluster channels, the command queue and other queues used by MQ system components are opened with exclusive use, regardless of the queue's default setting. Similarly, monitoring programs often open the event queues for exclusive use to ensure that other programs do not compete for messages and result in missed critical events. Is it one of the event or XMit queues? If so, you may not be able to remove the error without stopping the channel or monitoring agent. If it is a user-defined queue, use the DI
Regarding Reason code = 2042 Support for MQSeries and Websphere Message Oriented Middleware communication systems for z/OS Post a reply Previous topic • Next topic • 2 posts • Page 1 of 1 Regarding Reason code = 2042 by rekhamf » Fri Apr 13, 2012 6:57 pm Hi , When I try to run 2 batch jobs at same time which is pointing to same, the second job failed to execute with 2042 ( says object in use)in MQOPEN ..Do i need to specify any other definition here ?I gave : Select allCOMPUTE W-INPUT-OPENOPTIONS = MQOO-INPUT-SHARED + MQOO-SAVE-ALL-CONTEXT + MQOO-FAIL-IF-QUIESCING CALL 'MQOPEN' USING W-MQ-HCONN MQOD W-INPUT-OPENOPTIONS W-MQ-HOBJ-IN W-MQ-COMPCODE W-MQ-REASON I was try to execute in developement region .I too have doubt whether developement region will not allow the mq object to use at same time .Is that possible ? rekhamf Posts: 33Joined: Mon Nov 28, 2011 5:09 am Hasthanked: 0 time Beenthanked: 0 time Top Re: Regarding Reason code = 2042 Top Re: Regarding Reason code = 2042 by dick scherrer » Sat Apr 14, 2012 12:11 am Hello,Suggest you find a way to ensure these jobs only run single thread (one at a time). Hope this helps,d.sch. dick scherrer Global moderator Posts: 6308Joined: Sat Jun 09, 2007 8:58 am Hasthanked: 3 times Beenthanked: 90 times Top Display posts from previous: All posts1 day7 days2 weeks1 month3 months6 months1 year Sort by AuthorPost timeSubject AscendingDescending Post a reply Previous topic • Next topic • 2 posts • Page 1 of 1 Return to WebSphere MQ Jump to: Select a forum ------------------ ANNOUNCEMENTS Forum Rules Site Announcements Suggestions & Feedback Mainframe Related Videos PROGRAMMING LANGUAGES IBM Cobol CLIST & REXX PL/I Assembler Natural C, C++ CA-Easytrieve Mainframe Java JOB & TRANSACTION PROCESSING JCL CICS TSO & ISPF WebSphere MQ DATA MANAGEMENT SYSTEMS DB2 VSAM/SMS IMS DB/DC IDMS/ADSO Adabas IBM UTILITIES & TOOLS DFSORT/ICETOOL/ICEGENER Language Environment IBM Debug Tool Other IBM Tools 3rd PARTY MAINFRAME TOOLS File-AID Abend-AID Xpediter ChangeMan ZMF Panvalet CA-7 CA-11 All Other Tools Syncsort/Synctool DEBUGGING & TESTING Application Testing ABENDS & SQL Codes OTHER MAINFRAME TOPICS Operating Systems Ma