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 Index » WebSphere Message Broker (ACE) Support » To send Ebcdic data barring few fields which are packed deci

Post new topic  Reply to topic
 To send Ebcdic data barring few fields which are packed deci « View previous topic :: View next topic » 
Author Message
phanish
PostPosted: Wed Jan 08, 2014 7:10 am    Post subject: To send Ebcdic data barring few fields which are packed deci Reply with quote

Apprentice

Joined: 04 May 2013
Posts: 30

Hi,

I am stuck with an issue where in I have to outbound data in Ebcdic format barring few fields which are packed decimal, zoned integer and zoned decimal.

I Imported the cobol copy book in Binary CWF and I can see physical type as packed decimal for the fields which should be packed decimal in the Message set but for zoned integer/decimal fields physical type is as decimal.

rest of the fields I have to send it in ebcdic form. as of now I am casting as the below for the ebcidic fields
Code:

SET target.MRM.PATH_OSHDR_DATA.PATH_OSHDR_OSLPR_COUNT = CAST(TRIM(source.XMLNSC.createEquipmentOrder.leaseSegmentCount) AS BLOB CCSID 37 ENCODING 785)


and for non ebcdic fields I am mapping as

Code:
SET target.MRM.PATH_OSHDR_DATA.PATH_OSHDR_OSLTYP = CAST(TRIM(source.XMLNSC.createEquipmentOrder.leaseTypeCode) AS BLOB CCSID 546 ENCODING 785);


And I am seeing the error
"Text:CHARACTER:Error creating converter"

could you pls help me in resolving this and also I am unsure whether I am doing it in optimal way
[/code]
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed Jan 08, 2014 7:27 am    Post subject: Reply with quote

Grand High Poobah

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

Why are you using CAST to turn things into a BLOB and then assigning it to an MRM message tree?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
phanish
PostPosted: Wed Jan 08, 2014 8:07 am    Post subject: Reply with quote

Apprentice

Joined: 04 May 2013
Posts: 30

because when I just casted as it's original primitive type with ccsid as 37. I am seeing the output in ascii only and I dont see any ebcidic data in the output
Back to top
View user's profile Send private message
phanish
PostPosted: Wed Jan 08, 2014 10:11 am    Post subject: Reply with quote

Apprentice

Joined: 04 May 2013
Posts: 30

is it possible to do field level casting into ebcdic and have the output domain as MRM?
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Jan 09, 2014 2:43 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Don't try to CAST to EBCDIC in your message flow! The message tree is a canonical representation of your data, and all text data is in UTF-16.

The WMB parser ( MRM in your case ) will cast to EBCDIC when it writes the text fields to the output. Just make sure that you set OutputRoot.Properties.CodedCharSetId correctly.
_________________
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
View user's profile Send private message
Vitor
PostPosted: Thu Jan 09, 2014 4:04 pm    Post subject: Reply with quote

Grand High Poobah

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

kimbert wrote:
Don't try to CAST to EBCDIC in your message flow! The message tree is a canonical representation of your data, and all text data is in UTF-16.

The WMB parser ( MRM in your case ) will cast to EBCDIC when it writes the text fields to the output. Just make sure that you set OutputRoot.Properties.CodedCharSetId correctly.




It is for this point I asked the question above.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
phanish
PostPosted: Fri Jan 10, 2014 3:03 am    Post subject: Reply with quote

Apprentice

Joined: 04 May 2013
Posts: 30

In my case not all the fields are ebcdic, few fields are packed decimal and few are zoned integer, and my broker version is 7.0. Can you please suggest me how to handle this.
Back to top
View user's profile Send private message
smdavies99
PostPosted: Fri Jan 10, 2014 4:51 am    Post subject: Reply with quote

Jedi Council

Joined: 10 Feb 2003
Posts: 6076
Location: Somewhere over the Rainbow this side of Never-never land.

All of your fields can be described on a Cobol Copy book.

google for
cobol zoned numeric

cobol packed decimal

Create a message model that properly describes your output and let the MRM parser work its magic for you.
_________________
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
View user's profile Send private message
kimbert
PostPosted: Fri Jan 10, 2014 5:13 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
not all the fields are ebcdic, few fields are packed decimal and few are zoned integer
That's OK - the MRM parser knows which fields are text and which are non-text. It will only apply the EBCDIC encoding to the text fields.

Does that answer your concerns?
_________________
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
View user's profile Send private message
phanish
PostPosted: Wed Jan 15, 2014 11:40 pm    Post subject: Reply with quote

Apprentice

Joined: 04 May 2013
Posts: 30

thanks Kimbert.

I understood that even though we set the ccsid and encoding at message set level (OutputRoot.MQMD.CodedCharSetId=37), EBCDIC conversion is applicable only to the fields which are of character type and the packed decimal fields will remain non ebcdic. Infact this will meet my requirement.
could you please correct me if I am wrong.
Back to top
View user's profile Send private message
kimbert
PostPosted: Thu Jan 16, 2014 2:24 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Your understanding is correct.

A message model can save you a lot of development time. It means that you can ignore the physical format of your data, and design your message flow to deal with the logical representation of the data. (Exactly what DOM does for XML).

If you are interested, you might like to download the free IIB v9 developer toolkit and experiment with the DFDL parser.
_________________
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
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » To send Ebcdic data barring few fields which are packed deci
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.