|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Call to MQI MQCONN fails |
« View previous topic :: View next topic » |
Author |
Message
|
NewYa3am |
Posted: Mon Jan 04, 2010 9:29 am Post subject: Call to MQI MQCONN fails |
|
|
Newbie
Joined: 14 Oct 2009 Posts: 8
|
Hello,
I'm using this http://www-01.ibm.com/support/docview.wss?rs=171&uid=swg24007060&loc=en_US&cs=utf-8&lang=en SupportPac that implements the WebSphere MQI as a Pascal unit for Borland's Delphi.
My development platform contains:
-Windows XP
-Embarcadero Delphi 2010
-WebSphere MQ V6.0.0
The code I've written is just simple and straight forward. Here is my first Delphi code:
Code: |
unit Unit1;
interface
uses MQI;
procedure run;
implementation
procedure run;
var
Hconn : MQHCONN;
ConnectOpts : MQCNO;
CompCode, Reason : MQLONG;
QMgrName : MQCHAR48;
begin
QMgrName := 'QMGR_1'#0;
MQCONN ( @QMgrName, @HConn, @Compcode, @Reason );
writeln( 'Completion Code: ' , CompCode , ', Reason: ' , Reason );
if CompCode <> MQCC_OK then
writeln( 'failed to connect' )
else
writeln( 'connected' );
end;
end.
|
and that's the result I get
Code: |
Completion Code: 2, Reason: 2058
failed to connect |
Which means there is an error in the queue manager name but I've made sure that the name is absolutely correct. I've tried to use blanks as the name of the queue manager but I get the reason code 2059 which implies the default queue manager is not available.
I've made a call through the Java implementation and it worked fine.
Any help, please. |
|
Back to top |
|
 |
Vitor |
Posted: Mon Jan 04, 2010 10:08 am Post subject: Re: Call to MQI MQCONN fails |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
NewYa3am wrote: |
the result I get
Code: |
Completion Code: 2, Reason: 2058
failed to connect |
Which means there is an error in the queue manager name but I've made sure that the name is absolutely correct. |
It might be right in your code, but is it right in the CCDT?
NewYa3am wrote: |
I've tried to use blanks as the name of the queue manager but I get the reason code 2059 which implies the default queue manager is not available. |
No it doesn't. It implies the queue managers in the CCDT (which may or may not be the default) are unavailable, which might simply mean unreachable from where your code is running.
Use the usual techniques for resolving a 2059. You'll find your piece of working Java an invaluable aid here. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|