Author |
Message
|
yamini |
Posted: Wed Jun 01, 2011 4:43 am Post subject: wat is alt of MQQueue._getConnectionCCSID() method in mq7 |
|
|
Newbie
Joined: 01 Jun 2011 Posts: 1
|
How can i get the character set (CCSID) information of a MQQueue connection using java mq api in WMQ7?
In MQ6 we are using a method called MQQueue._getConnectionCCSID() for this operation, is there any other alternative method for this MQ7. |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Jun 01, 2011 4:48 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
A queue does not have a CCSID on it's own, so the fact that you were accessing this from an MQQueue object reflects some confusion somewhere.
There is a getCharacterSet method, but it is properly on the MQQueueManager object in v7. |
|
Back to top |
|
 |
fjb_saper |
Posted: Wed Jun 01, 2011 1:24 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Looks to me like there is confusion with java base and java JMS.
In JMS the queue (aka Destionation) can have a CCSID.
Have fun  _________________ MQ & Broker admin |
|
Back to top |
|
 |
mqjeff |
Posted: Wed Jun 01, 2011 2:07 pm Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
fjb_saper wrote: |
Looks to me like there is confusion with java base and java JMS.
In JMS the queue (aka Destionation) can have a CCSID. |
Sure, but JMS code wouldn't be calling methods on MQQueue objects.
 |
|
Back to top |
|
 |
fjb_saper |
Posted: Wed Jun 01, 2011 9:07 pm Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
mqjeff wrote: |
fjb_saper wrote: |
Looks to me like there is confusion with java base and java JMS.
In JMS the queue (aka Destionation) can have a CCSID. |
Sure, but JMS code wouldn't be calling methods on MQQueue objects.
 |
No but AFAIK the user code could cast the Destination to MQQueue (not the same as in java base, see package com.ibm.mq.jms)... and thus in a stack trace you might find MQQueue as the class implementing javax.jms.Queue and javax.jms.Destination, com.ibm.mq.jms.MQDestination?  _________________ MQ & Broker admin |
|
Back to top |
|
 |
rekarm01 |
Posted: Thu Jun 02, 2011 12:21 am Post subject: Re: wat is alt of MQQueue._getConnectionCCSID() method in mq |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 1415
|
The WMQv6 base Java API has an undocumented method com.ibm.mq.MQQueue._getConnectionCCSID(), which returns the queue's queuemanager's session's connection ccsid, whatever that is.
The WMQv7 base Java API does not have the same method, although it may provide an alternate, undocumented method.
It's difficult to rely on undocumented methods.
How is the returned connection ccsid used? Perhaps there's a documented alternative that would work just as well. |
|
Back to top |
|
 |
Vitor |
Posted: Thu Jun 02, 2011 4:10 am Post subject: Re: wat is alt of MQQueue._getConnectionCCSID() method in mq |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
rekarm01 wrote: |
It's difficult to rely on undocumented methods.
|
Because they sometimes disappear without warning when the release changes?  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
|