ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum IndexGeneral IBM MQ SupportData conversion between queue managers

Post new topicReply to topic
Data conversion between queue managers View previous topic :: View next topic
Author Message
amiivas
PostPosted: Wed Jul 17, 2019 1:51 am Post subject: Data conversion between queue managers Reply with quote

Apprentice

Joined: 14 Oct 2007
Posts: 44
Location: Texas, USA

Hi,

I am trying to do data conversion using Sender channel conversion feature from one of the Mainframe queue having ccsid of 37 to a distributed queue manager having ccsid of 819. What I believe is if I put an EBCDIC message in a remote queue of mainframe queue manager it should be converted to ASCII while reading the message from distributed queue manager without explicitly giving MQGMO_CONVERT option by application reading the message.

Is it possible for queue manager to do the conversion from EBCDIC to ASCII so that reading application can use default options to read the message in ASCII.

Thanks.
_________________
IBM WebSphere Certified Solution Developer
Back to top
View user's profile Send private message
bruce2359
PostPosted: Wed Jul 17, 2019 3:41 am Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 8519
Location: US: west coast, almost. Otherwise, enroute.

When you try, what are the results?

Do you mean CONVERT(YES) on the sender channel?

Any errors written to the errors files?
_________________
There are two types of people in this world:
1) Those that can extrapolate from incomplete data
Back to top
View user's profile Send private message
amiivas
PostPosted: Wed Jul 17, 2019 4:23 am Post subject: Reply with quote

Apprentice

Joined: 14 Oct 2007
Posts: 44
Location: Texas, USA

Quote:
When you try, what are the results?

the message is not getting converted. I am still getting EBCDIC format in the destination queue. Tried to change the CCSID of the message to 37 while posting the message but no luck.

Quote:
Do you mean CONVERT(YES) on the sender channel?

Yes

Quote:
Any errors written to the errors files?

Unfortunately do not have access to Mainframe logs, but if the error logs are any helpful then I have to setup new queue managers with different CCSID on my laptop.

Thanks.
_________________
IBM WebSphere Certified Solution Developer
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Jul 17, 2019 5:33 am Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 25850
Location: Texas, USA

amiivas wrote:
the message is not getting converted. I am still getting EBCDIC format in the destination queue. Tried to change the CCSID of the message to 37 while posting the message but no luck.


Is the message indicated to be a string in the MQMD? If it's not it won't be converted any more than an MQGet with convert would.

Slightly off topic but a note of caution:

Be very sure that the message conceptually is a string. Personal experience as a guy who wrote mainframe code professionally before he used MQ professionally to receive mainframe messages makes me slightly suspicious that a mainframe app is putting plain text. They're much more likely to be putting a combination of text and packed numeric values and "assuming" that when you say convert, you mean convert the whole thing. Including their packed numbers into an endian format. A lot of people over the years have given me a "deer in headlights" look and said

Quote:
but you said you were converting it


So if & when the text turns into ASCII but there's still unprintable characters dotted through it, that's something to bear in mind.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
bruce2359
PostPosted: Wed Jul 17, 2019 7:14 am Post subject: Reply with quote

Poobah

Joined: 05 Jan 2008
Posts: 8519
Location: US: west coast, almost. Otherwise, enroute.

amiivas wrote:
Tried to change the CCSID of the message to 37 while posting the message but no luck.

The purpose of the MQMD CCSID field is to tell the downstream qmgr and/or app about the app data component. Changing the MQMD CCSID field does NOT change the application data.

Think of the MQMD as an envelope into which you place a letter to your significant other. If the letter is written in English, but you write on the envelope 'letter enclosed is written in French' you have the equivalent of you changing the MQMD CCSID - the app data (letter) remains unchanged.
_________________
There are two types of people in this world:
1) Those that can extrapolate from incomplete data
Back to top
View user's profile Send private message
amiivas
PostPosted: Wed Jul 17, 2019 9:13 pm Post subject: Reply with quote

Apprentice

Joined: 14 Oct 2007
Posts: 44
Location: Texas, USA

Quote:
The purpose of the MQMD CCSID field is to tell the downstream qmgr and/or app about the app data component. Changing the MQMD CCSID field does NOT change the application data


That was the whole intention of putting CCSID 37 was to let destination queue manager that the incoming message is EBCDIC format hoping that when it finally commit the message into its local queue it converts its into it own code page.

Quote:
Is the message indicated to be a string in the MQMD?

Yes the message is in string format as I am able to change it to ASCII using TextFX conversion tool.The ASCII data is without any special characters.

The question is whether data can be converted automatically using this feature?
If yes, then finding solution can be interesting but if not then no point in beating the bushes.

Thanks.
Thanks.
_________________
IBM WebSphere Certified Solution Developer
Back to top
View user's profile Send private message
hughson
PostPosted: Thu Jul 18, 2019 1:58 am Post subject: Reply with quote

Grand Master

Joined: 09 May 2013
Posts: 1277
Location: Bay of Plenty, New Zealand

amiivas wrote:
The question is whether data can be converted automatically using this feature?

If you say CONVERT(YES) on a sender channel, this causes the sender channel to do an MQGET with MQGMO_CONVERT of the message from the transmission queue. This will convert the message (just as an application MQGET with MQGMO_CONVERT would convert it when picking it up from the target queue).

The conversion will only work, as already noted, if the MQMD.Format field is set to MQFMT_STRING, or another well known format, or a format for which you have a data-conversion exit; and the correct codepage (and encoding if not just a string) have been set in the MQMD.CCSID and MQMD.Encoding fields.

Cheers,
Morag
_________________
Morag Hughson @MoragHughson
IBM MQ Technical Education Specialist
Get your IBM MQ training here!
MQGem Software
Back to top
View user's profile Send private message Visit poster's website
gbaddeley
PostPosted: Thu Jul 18, 2019 4:27 pm Post subject: Reply with quote

Jedi

Joined: 25 Mar 2003
Posts: 2036
Location: Melbourne, Australia

The general recommendation is to not use the sender channel CONVERT(YES) feature, as it is usually a band-aid fix for sloppy application design and programming, that should never have been an issue in the first place. I was forced to use this feature once, and in hindsight it was more trouble that what it was worth, as it impacts all STRING format messages on the channel.
_________________
Glenn
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexGeneral IBM MQ SupportData conversion between queue managers
Jump to:



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
Protected by Anti-Spam ACP


Theme by Dustin Baccetti
Powered by phpBB 2001, 2002 phpBB Group

Copyright MQSeries.net. All rights reserved.