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 » Handling IDOC double byte in IIB

Post new topic  Reply to topic
 Handling IDOC double byte in IIB « View previous topic :: View next topic » 
Author Message
Harsha_AS
PostPosted: Wed May 27, 2015 11:15 pm    Post subject: Handling IDOC double byte in IIB Reply with quote

Apprentice

Joined: 04 Dec 2011
Posts: 26

We are getting the IDOC data from SAP in which they are sending UTF16 data.
In the IDOC data they are sendign double byte data as well. We are receiving these IDOC message through SAPINPUT node with Code page set 4102.
Once we receive IDOC message We have DFDL created (FixedLength) to parse this data.
Our flow is failing when we get the double byte data in IDOC message due to lenght missmatch.
In DFDL i have set the Encoding (code page) as <dynamically set>
Could you please let me know how to handle this double byte message in DFDL while parsing.
Back to top
View user's profile Send private message Send e-mail
maurito
PostPosted: Wed May 27, 2015 11:41 pm    Post subject: Re: Handling IDOC double byte in IIB Reply with quote

Partisan

Joined: 17 Apr 2014
Posts: 358

Harsha_AS wrote:
We are getting the IDOC data from SAP in which they are sending UTF16 data.
In the IDOC data they are sendign double byte data as well. We are receiving these IDOC message through SAPINPUT node with Code page set 4102.
Once we receive IDOC message We have DFDL created (FixedLength) to parse this data.
Our flow is failing when we get the double byte data in IDOC message due to lenght missmatch.
In DFDL i have set the Encoding (code page) as <dynamically set>
Could you please let me know how to handle this double byte message in DFDL while parsing.


in your DFDL model, have you set the Length Unit property to characters ?
Back to top
View user's profile Send private message
Harsha_AS
PostPosted: Thu May 28, 2015 1:03 am    Post subject: Reply with quote

Apprentice

Joined: 04 Dec 2011
Posts: 26

i Had the Length Unit Property has Bytes. I changed it to characters and tested it. But i am still getting thesame parse error.
Back to top
View user's profile Send private message Send e-mail
maurito
PostPosted: Thu May 28, 2015 1:07 am    Post subject: Reply with quote

Partisan

Joined: 17 Apr 2014
Posts: 358

Harsha_AS wrote:
i Had the Length Unit Property has Bytes. I changed it to characters and tested it. But i am still getting thesame parse error.

you will need to supply more info if you want people to help. For example: the DFDL model, an example of the input data, the parser trace
Back to top
View user's profile Send private message
Harsha_AS
PostPosted: Thu May 28, 2015 2:00 am    Post subject: Reply with quote

Apprentice

Joined: 04 Dec 2011
Posts: 26

Below is the Hex data coming from SAP
0049004e0056004900450057002000440061007300680062006f00610072006400202013002000530069006e0067006c006500200055006e00690074002000280044004d0033003000300029

Below is the ASCII convertion
INVIEW Dashboard !! Single Unit (DM300)

You can see in the hex data there is a double byte "2013" which is converted in to ASCII "!!"

In my DFDL when it parsses this double byte "2013" it is converting it to ASCII "!!" where the actual value of double byte "2013" is "–"
Could you please let me know what encoding i need to use in DFDL to handle this scenario.

Or is it something else that i need to take care.
Back to top
View user's profile Send private message Send e-mail
maurito
PostPosted: Thu May 28, 2015 2:13 am    Post subject: Reply with quote

Partisan

Joined: 17 Apr 2014
Posts: 358

Harsha_AS wrote:
Below is the Hex data coming from SAP
0049004e0056004900450057002000440061007300680062006f00610072006400202013002000530069006e0067006c006500200055006e00690074002000280044004d0033003000300029

Below is the ASCII convertion
INVIEW Dashboard !! Single Unit (DM300)

You can see in the hex data there is a double byte "2013" which is converted in to ASCII "!!"

In my DFDL when it parsses this double byte "2013" it is converting it to ASCII "!!" where the actual value of double byte "2013" is "–"
Could you please let me know what encoding i need to use in DFDL to handle this scenario.

Or is it something else that i need to take care.

Test parse your model using that message and pick the correct encoding. Have a guess at which one to use
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Thu May 28, 2015 5:40 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

U2013 in UTF-8 is N-DASH which looks like a - but has a different hex code.
Often a problem when copying from MS Word.
This is a punctuation character. It looks like a dash but is not and has a different hex value. I'd say your SAP system is not sending the right value (unlikely) or does not have the right value in it's source (more likely).

Have fun
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Handling IDOC double byte in IIB
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.