Author |
Message
|
osudheer |
Posted: Thu Dec 18, 2014 12:06 pm Post subject: how to set ASCII and EBCDIC formats in same message |
|
|
Newbie
Joined: 24 Oct 2010 Posts: 8
|
Hi,
There is requirement to set part of the message in ASCII and part of the message in EBCDIC before calling the system from message broker flow.
Is it possible to set like this.
Please guide me.
Thanks,
Sudheer |
|
Back to top |
|
 |
Vitor |
Posted: Thu Dec 18, 2014 12:20 pm Post subject: Re: how to set ASCII and EBCDIC formats in same message |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
osudheer wrote: |
There is requirement to set part of the message in ASCII and part of the message in EBCDIC before calling the system from message broker flow. |
Is this a technical requirement or someone's weird business requirement? Why, exactly, do you need to do this and what exactly is consuming the message?
osudheer wrote: |
Is it possible to set like this. |
It's possible to create a message that has ASCII and EBCDIC components. You can't set a message to be both because that doesn't make sense, so (for example) the MQMD can only be set to a single CCSID or (again only as an example) the declaration on an XML doc can only hold 1 CCSID.
osudheer wrote: |
Please guide me. |
Tell whoever gave you this requirement they're barking mad. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
McueMart |
Posted: Fri Dec 19, 2014 2:50 am Post subject: |
|
|
 Chevalier
Joined: 29 Nov 2011 Posts: 490 Location: UK...somewhere
|
If you are using a DFDL model for example, you can define the output to contain multiple different character encodings (each field can have it's own encoding).
You havent given enough information about what the 'message' is which you are passing to the downstream system for us to be able to help you much. |
|
Back to top |
|
 |
kimbert |
Posted: Fri Dec 19, 2014 4:42 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
The answer is 'yes'. But we cannot tell you what to do unless you explain the problem in more detail. Please supply at least one example of what you are trying to do. _________________ Before you criticize someone, walk a mile in their shoes. That way you're a mile away, and you have their shoes too. |
|
Back to top |
|
 |
osudheer |
Posted: Fri Dec 26, 2014 10:36 am Post subject: |
|
|
Newbie
Joined: 24 Oct 2010 Posts: 8
|
We are trying to call a service from tcpip ..we need to send message with header in ascii and body in ebcdic. |
|
Back to top |
|
 |
kimbert |
Posted: Fri Dec 26, 2014 5:39 pm Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
Use the DFDL property 'Encoding'. It is available on every element and sequence group definition. Normally, a DFDL schema sets it in the 'global format block' and then every DFDL element/group inherits the same setting.
You can override it on any specific element, and set it to whatever you need.
Note that properties are not 'inherited' from a complex element so you will need to set the encoding on each text element in the header. That could be tedious, so the better solution is
- define the header and all of its child elements in a separate xsd
- create a new global format block for the header xsd and set the encoding there.
If you don't know what a 'format block' is then you should probably do a bit of background reading on that. There are some good videos by Steve Hanson out there. _________________ Before you criticize someone, walk a mile in their shoes. That way you're a mile away, and you have their shoes too. |
|
Back to top |
|
 |
|