Author |
Message
|
SOLOHERO |
Posted: Wed Jul 04, 2007 11:18 pm Post subject: Coverting from XML to EBCDIC |
|
|
Centurion
Joined: 01 Feb 2007 Posts: 107
|
hi ,
here is a scenerio where i am converting xml message to copy books in mainframes.
Where do i set the convertcode values and what values do i have to set . _________________ Thanks |
|
Back to top |
|
 |
Vitor |
Posted: Wed Jul 04, 2007 11:58 pm Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
So you've converting XML into Cobol(?) copy book layout?
I'll assume the XML is from an ASCII based Win/Unix platform so the first conversion is automatic provided the XML is sent as a string and the mainframe has appropriate conversion tables (I'd be surprised if not).
To convert the format, use a maping node, convert node or other WMB method of your choice. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
wbi_telecom |
Posted: Thu Jul 05, 2007 7:50 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
You will have to set Encoding and CCSID values in MQMD when you send the message to mainframe (from meomary they are 500 and 785 but its better if you check a better reference)
Cheers, |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu Jul 05, 2007 7:54 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
You set Encoding & CCSID to the values that match what encoding and CCSID the data is currently IN, not the value that the data WILL be in.
And you set MQMD.Format = MQFMT_STRING.
And the receiving app sets MQGMO_CONVERT. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
wbi_telecom |
Posted: Thu Jul 05, 2007 8:13 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
From IBM Infocenter
An example WebSphere MQ message has an MQMD header, an MQRFH2 header, and a message body. To convert this message to a mainframe CodedCharSetId and Encoding, code the following ESQL in the Compute node:
SET OutputRoot.MQMD.CodedCharSetId = 500;
SET OutputRoot.MQMD.Encoding = 785;
SET OutputRoot.MQRFH2.CodedCharSetId = 500;
SET OutputRoot.MQRFH2.Encoding = 785;
Cheers, |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu Jul 05, 2007 8:20 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
Right, that will cause the message to be output to the queue in that codepage/encoding.
Which is maybe not what's wanted. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
wbi_telecom |
Posted: Thu Jul 05, 2007 8:31 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
Ohh Ok. I am assuming things like an ASCII to EBCDIC conversion using a message flow that gets an XML in input queue on Windows/Unix and send out a CWF message to a output queue on mainframe. Please disreagrd my suggestion if that's not what you are looking for.
Cheers, |
|
Back to top |
|
 |
SOLOHERO |
Posted: Thu Jul 05, 2007 3:50 pm Post subject: |
|
|
Centurion
Joined: 01 Feb 2007 Posts: 107
|
what is the purpose of setting MQRFH2 Header. _________________ Thanks |
|
Back to top |
|
 |
Vitor |
Posted: Fri Jul 06, 2007 12:03 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
SOLOHERO wrote: |
what is the purpose of setting MQRFH2 Header. |
It tells WMB or JMS things they need to know which are not contained in the MQMD _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
wbi_telecom |
Posted: Fri Jul 06, 2007 6:41 am Post subject: |
|
|
 Disciple
Joined: 15 Feb 2006 Posts: 188 Location: Harrisburg, PA
|
Don't bother to set RFH2 header in case your target application does not need it. As I wrote I did a copy paste from Infocenter example. Even if you set the CCSID and Encoding in MQMD and Properties you are good.
Cheers, |
|
Back to top |
|
 |
|