Author |
Message
|
vijaychand |
Posted: Mon Jan 09, 2012 7:13 pm Post subject: converting form ASIIC to EBCDIC format |
|
|
Novice
Joined: 29 Nov 2011 Posts: 12
|
hi all,
what are the CodedCharSetId and Encoding values for EBCDIC format. |
|
Back to top |
|
 |
smdavies99 |
Posted: Mon Jan 09, 2012 10:51 pm Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
There are quite a few variants of EBCIDIC. You should find out what the target system is using.
For example,
https://www-304.ibm.com/support/docview.wss?uid=swg21197185
This shows the difference between 37 and 500 and 1047
Your question is not as simple as you might think to answer.
There again, nothing relating to CCSID & Character mappings is ever as simple as it might seem. The number of posts here on this subject is clear evidence of this. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
Vitor |
Posted: Tue Jan 10, 2012 5:38 am Post subject: Re: converting form ASIIC to EBCDIC format |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
vijaychand wrote: |
what are the CodedCharSetId and Encoding values for EBCDIC format. |
The ones your Z/os system is set to use.
It's like asking what the CCSID & encodings are for ASCII. There's no single answer. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
vijaychand |
Posted: Tue Jan 10, 2012 9:57 pm Post subject: |
|
|
Novice
Joined: 29 Nov 2011 Posts: 12
|
Thanks ebvery one ...
but any one can suggest what is the encoding for EBDIC . which rfhtuilc can display . |
|
Back to top |
|
 |
smdavies99 |
Posted: Tue Jan 10, 2012 10:12 pm Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
vijaychand wrote: |
Thanks ebvery one ...
but any one can suggest what is the encoding for EBDIC . which rfhtuilc can display . |
rfhutil will display the data using the CCSID it gets from the MQMD in the message.
If the CCSID is wrong then the character representation of the data will be wrong. Get some EBCIDIC data from your Mainframe. Look at the CCSID in the MQMD. Then look at the link I previously posted. If the characters that are different between say CCSId 37 & 500 match what you are seeing then the CCSID in the message is correct. If they are not then you have to go back to the source and tell them very nicely that they have messed up. It does happen you know!
There is a thread from a few days ago
http://www.mqseries.net/phpBB2/viewtopic.php?t=59979
I suggest you read it, especially the post by kimbert that contaons some links. This will help you understand the whole topic.
When you do 'get it', using data that comes from all these wierd and strange systems will suddenly become a lot easier. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
vijaychand |
Posted: Wed Jan 11, 2012 1:37 am Post subject: |
|
|
Novice
Joined: 29 Nov 2011 Posts: 12
|
thank you very much ...
i am able to conert if it is an xmlnsc with below code ...
SET OutputRoot.MQMD.CodedCharSetId = 500;
SET OutputRoot.MQMD.Encoding = 785;
but if it is BLOB we are facing a problem .. please can any one help |
|
Back to top |
|
 |
kimbert |
Posted: Wed Jan 11, 2012 1:44 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
You don't understand the problem that you are solving. Guessing the CCSID is the wrong approach - it might make your test data work, but that does not prove anything.
Quote: |
but if it is BLOB we are facing a problem |
I don't understand that statement. Everything is a BLOB when it is 'on the wire'. Are you writing two different message flows, one that takes a BLOB and one that takes XML?
I still recommend those links that smdavies99 mentioned - they really are good. |
|
Back to top |
|
 |
vijaychand |
Posted: Wed Jan 11, 2012 1:56 am Post subject: |
|
|
Novice
Joined: 29 Nov 2011 Posts: 12
|
sorry ...
the CCSID is the target system id(LEGACY).. i have 2 flows .. one which have BLOB and other is XML ...
thanks for your info |
|
Back to top |
|
 |
smdavies99 |
Posted: Wed Jan 11, 2012 2:05 am Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
vijaychand wrote: |
but if it is BLOB we are facing a problem .. please can any one help |
A BLOB is a BLOB is a BLOB
B - Binary
L - Large
OB - Object
BLOB's don't have CCSID's. They are a string of binary data.
As kimbert says, when a BLOB or XML or even a 'Tooth Fairy' formatted messages are on the wire, they are all BLOB's. You only need to understand the format of the data in a BLOB when to want to parse it. Then you need to know the CCSID of the data when it was turned into a BLOB.
Go and talk to the z/OS SysAdmins and find out what the native CCSID of the QMGR's on the sytstems are.
Then talk to the App developers and find out if they are using something other than the Default CCSID when they are senting the message to you.
Use the results of that in your code.
As kimbert says, 'Don't try to guess'. It may work in these but I can guarantee that it will fail when it gets into production. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
|