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 IndexGeneral IBM MQ SupportProblem with Encoding characters set

Post new topicReply to topic
Problem with Encoding characters set View previous topic :: View next topic
Author Message
SABCAS
PostPosted: Mon May 29, 2006 1:01 am Post subject: Problem with Encoding characters set Reply with quote

Acolyte

Joined: 09 Mar 2005
Posts: 60
Location: Switzerland

Hallo,
I have a little problem with Encoding Character set, I receive into XML a Text value and is in Germany wroten for example "Ich bin müde". Now I try to copy the Values from Input XML into a Output XML and then I convert the Output XML into a string type with the following command:
DECLARE myString CHARACTER CAST(ASBITSTREAM(OutputRoot.XMLNS OPTIONS RootBitStream) AS CHARACTER CCSID InputRoot.MQMD.CodedCharSetId ENCODING InputRoot.MQMD.Encoding);

Normaly I used the following Set Characters:
SET OutputRoot.MQMD.Encoding = 546;
SET OutputRoot.MQMD.CodedCharSetId = 819;

But I receive like follow:
<ExternalRef>Ich bin mde</ExternalRef>
Correctly I have seeing: <ExternalRef>Ich bin müde</ExternalRef>

I try also CCSID=500 but without success.
Thanks in Advance for your Help and suggestion
Ciao
Sabatojavascript:emoticon('')
javascript:emoticon('')
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Mon May 29, 2006 3:00 am Post subject: Reply with quote

Grand High Poobah

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

Well talking about XML you should not have seen
Quote:
<ExternalRef>Ich bin müde</ExternalRef>

Although the content is correct and the text is certainly right the XML version should look different due to XML encoding.... especially if something like UTF-8 is used: <tag>Ich bin m&uumlautde</tag> or something like it. Think about & being &amp within the XML stream.

The problem is probably your CCSID transform that does not take into account the CCSID of the source with the XML type. You should check if there is an XML transform (see XML encoding values) and set the CCSID accordingly.(1208 and not 819 etc ...)

Enjoy
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
SABCAS
PostPosted: Mon May 29, 2006 7:12 am Post subject: Reply with quote

Acolyte

Joined: 09 Mar 2005
Posts: 60
Location: Switzerland

Hallo,
I tryed like you have suggested, but the problem still remains, here is my trace :
2006-05-29 16:46:48.700
****************************************
(
(0x01000000):Properties = (
(0x03000000):MessageSet = NULL
(0x03000000):MessageType = NULL
(0x03000000):MessageFormat = 'XMLNS'
(0x03000000):Encoding = 546
(0x03000000):CodedCharSetId = 1208
(0x03000000):Transactional = TRUE
(0x03000000):Persistence = TRUE
(0x03000000):CreationTime = GMTTIMESTAMP '2006-05-29 14:46:48.700'
(0x03000000):ExpirationTime = -1
(0x03000000):Priority = 0
(0x03000000):ReplyIdentifier = X'000000000000000000000000000000000000000000000000'
(0x03000000):ReplyProtocol = 'MQ'
(0x03000000):Topic = NULL
)
(0x01000000):MQMD = (
(0x03000000):SourceQueue = 'SIF.NIB.RECEIVE.A'
(0x03000000):Transactional = TRUE
(0x03000000):Encoding = 546
(0x03000000):CodedCharSetId = 1208
(0x03000000):Format = 'MQSTR '
(0x03000000):Version = 2
(0x03000000):Report = 0
(0x03000000):MsgType = 8
(0x03000000):Expiry = -1
(0x03000000):Feedback = 0
(0x03000000):Priority = 0
(0x03000000):Persistence = 1
(0x03000000):MsgId = X'414d5120514d5f736265313533323420dd567a442000a602'
(0x03000000):CorrelId = X'000000000000000000000000000000000000000000000000'
(0x03000000):BackoutCount = 0
(0x03000000):ReplyToQ = 'SIF.MPM.ERROR.NSI.A'
(0x03000000):ReplyToQMgr = 'MPMQM1'
(0x03000000):UserIdentifier = 'WBIMBNSI'
(0x03000000):AccountingToken = X'0000000000000000000000000000000000000000000000000000000000000000'
(0x03000000):ApplIdentityData = ' '
(0x03000000):PutApplType = 26
(0x03000000):PutApplName = 'WMQI/NIBSIMFlow'
(0x03000000):PutDate = DATE '2006-05-29'
(0x03000000):PutTime = GMTTIME '14:46:48.700'
(0x03000000):ApplOriginData = ' '
(0x03000000):GroupId = X'000000000000000000000000000000000000000000000000'
(0x03000000):MsgSeqNumber = 1
(0x03000000):Offset = 0
(0x03000000):MsgFlags = 0
(0x03000000):OriginalLength = -1
)
(0x01000010):XMLNS = (
(0x01000000)urn:www.swisscom.ch/P3NIB.Web.Service/NewInstalledBaseV2:xml = (
(0x02000000): = '<?xml version="1.0" encoding="UTF-8"?><ServiceLocation xmlns="urn:www.swisscom.ch/P3NIB.Web.Service/NewInstalledBaseV2/ModifyServiceLocation" Phone="890000001"><NrWires>001</NrWires><TType>001</TType><SpeedProfileNrAccess>002</SpeedProfileNrAccess><OPStatus>003</OPStatus><ContractedServices><ContractedServiceChangeIsp ContrEleId="13" IspId="100077"><ContrEleIdNew>13</ContrEleIdNew><IspIdNew>100054</IspIdNew><CustomerClass>002</CustomerClass><LevelOfSupport>001</LevelOfSupport><ModemOwner>003</ModemOwner><SpeedProfileNrService>201</SpeedProfileNrService><SpeedProfileShapingDown>1200</SpeedProfileShapingDown><SpeedProfileShapingUp>200</SpeedProfileShapingUp><SessionType>002</SessionType><Mutation>006</Mutation><ExternalRef>Ref_mde</ExternalRef></ContractedServiceChangeIsp></ContractedServices></ServiceLocation>'
)
)
)
(
(0x01000000):Destination = (
(0x01000000):RouterList = (
(0x01000000):DestinationData = (
(0x03000000):labelname = 'TO_NIB_WEBSERVICE'
)
)
)
)
(
(0x01000000):Variables = (
(0x01000000):Application = (
(0x03000000):ActImplCorrelId = 'RUEAAAABAdCAAAAAAAAAAAAAAAAAAwAAAAEBxkAAAAAAAAAAAAAAAAADQQAAAAEB0IAEAAAAAAAAAABF'
(0x01000000):Resp = (
(0x03000000):SpeedProfNrService = '201'
)
(0x03000000):XmlString = '<?xml version="1.0" encoding="UTF-8"?><ServiceLocation xmlns="urn:www.swisscom.ch/P3NIB.Web.Service/NewInstalledBaseV2/ModifyServiceLocation" Phone="890000001"><NrWires>001</NrWires><TType>001</TType><SpeedProfileNrAccess>002</SpeedProfileNrAccess><OPStatus>003</OPStatus><ContractedServices><ContractedServiceChangeIsp ContrEleId="13" IspId="100077"><ContrEleIdNew>13</ContrEleIdNew><IspIdNew>100054</IspIdNew><CustomerClass>002</CustomerClass><LevelOfSupport>001</LevelOfSupport><ModemOwner>003</ModemOwner><SpeedProfileNrService>201</SpeedProfileNrService><SpeedProfileShapingDown>1200</SpeedProfileShapingDown><SpeedProfileShapingUp>200</SpeedProfileShapingUp><SessionType>002</SessionType><Mutation>006</Mutation><ExternalRef>Ref_mde</ExternalRef></ContractedServiceChangeIsp></ContractedServices></ServiceLocation>'
(0x03000000):Operation = 'ModifyServiceLocation'
)
(0x01000000):NSI_D4506 = (
(0x01000000):MpmInstanceContext = (
(0x03000000):NotifyDur1 = '0'
(0x03000000):NotifyTo = 'omsonly1'
(0x03000000):InstanceStartMode = 'automatic'
(0x03000000):InstanceText = ''
(0x03000000):InstanceFlowCtrl = 'OK'
(0x03000000):DesUpdate = 'A1=;N1=;N2=;P1=890000001;P2=100054;S1=premium;P3=;P4=;N3=;P5=;E1=;T2=;O1=6456475735;O2=mod;O3=cis;C1=BBCS DHCP Priv;S2=Max2000_100;S3=;'
(0x03000000):ExceptOwner = 'NSI_TSECONDWAYEXCEPTION'
)
(0x01000000):MpmErrorInfo = (
(0x03000000):ErrorCode = '0'
(0x03000000):ErrorSeverity = ''
(0x03000000):ErrorComponent = 'NIBS'
(0x03000000):ErrorText = ''
(0x03000000):ErrorDetail = ''
)
(0x01000000):BbcsServiceOrder = (
(0x01000000):BbcsServiceOrderHeader = (
(0x03000000):ACTI_DATE = '20060509'
(0x03000000):ACTI_TIME = '1324'
(0x03000000):Sfep = 'premium'
(0x03000000):EXT_REF = 'Ref_müde'
(0x03000000):MESSAGE_TYPE = ''
(0x03000000):ORDER_REF = '6456475735'
(0x03000000):ORDER_TYPE_WSG = 'SRV_CHANGE_ISP'
(0x03000000):VERSION = 'V06'
)
(0x01000000):MpmContext = (
(0x03000000):ProcId = ''
(0x03000000):ProcInstId = ''
(0x03000000):ActId = ''
(0x03000000):ActCorrelId = ''
(0x03000000):DataVersion = '1'
)
(0x01000000):BbcsAccess = (
(0x03000000):ACCESS_END_DATE = ''
(0x03000000):BB_NR_WIRES = '001'
(0x03000000):BB_TYPE = 'classical ADSL'
(0x03000000):DN_TYPE = ''
(0x03000000):DN_VN_SN = '0890000001'
(0x03000000):ORDER_TYPE_ACCESS = 'mod'
(0x03000000):Phone = '890000001'
(0x03000000):SPEED_PROFILE_NR_ACCESS = 'BBCS_256_1536_901'
(0x03000000):A_Port = 'ADSL-1-2-34-56'
(0x03000000):DslamHostname = 'ipc-bpa640-s-dm-01'
(0x03000000):DslamType = 'ASAM'
(0x03000000):BB_LOG_PORT_NR = ''
(0x03000000):OP_STATUS = '003'
)
(0x01000000):BbcsService = (
(0x03000000):BB_CUSTOMER_CLASS = '002'
(0x03000000):BB_LEVEL_OF_SUPPORT_SERVICE = '001'
(0x03000000):BB_ZONE = '001'
(0x03000000):CONTR_ELE_ID = 'BBCS DHCP Priv'
(0x03000000):CONTR_ELE_ID_OLD = 'BBCS DHCP Priv'
(0x03000000):Speed_Value_Shaping_Up = '200'
(0x03000000):Speed_Value_Shaping_Down = '1200'
(0x03000000):Internet_Profile_State = 'enabled'
(0x03000000):Internet_Profile_Network = 'BBCS'
(0x03000000):MODEM_OWNER = '003'
(0x03000000):ORDER_TYPE_SERVICE = 'cis'
(0x03000000):Provider = '100054'
(0x03000000):ProviderOld = '100077'
(0x03000000):SERVICE_END_DATE = ''
(0x03000000):SERVICE_START_DATE_TIME = '2006-04-27 12:00:00'
(0x03000000):SERVICE_TYPE = 'Flat'
(0x03000000):SPEED_PROFILE_NR_SERVICE = 'Max2000_100'
(0x03000000):TERMINATION = 'FWS'
(0x03000000):VoBB_Profile_State = ''
(0x03000000):VoBB_Profile_Network = ''
(0x03000000):Streaming_Profile_Upstream_BW = ''
(0x03000000):Streaming_Profile_Downstream_BW = ''
(0x03000000):Streaming_Profile_State = ''
(0x03000000):Streaming_Profile_Network = ''
(0x03000000):VLineId = '1890000001'
(0x03000000):BB_SES_TYPE = 'DHCP'
(0x03000000):MUT_CODE = '006'
(0x03000000):OP_Status = ''
)
)
)
(0x03000000):Testumgebung = 'omsonly1'
(0x01000000):OrderTypeService = (
(0x03000000):Service = 'CIS'
)
)
)

the Variable XMLString has the element <ExternalRef>Ref_mde</ExternalRef>
but the input value is
(0x01000000):NSI_D4506 = (
(0x03000000):EXT_REF = 'Ref_müde'

I send the XMLString to a WebServer and he send back 'Server was unable to process request'
Thanks a ot for your Help
Ciao
Sabato
Back to top
View user's profile Send private message
Tibor
PostPosted: Mon May 29, 2006 7:14 am Post subject: Reply with quote

Grand Master

Joined: 20 May 2001
Posts: 1033
Location: Hungary

fjb_saper wrote:
<tag>Ich bin m&uumlautde</tag> or something like it.
Between ampersand and semicolon:
Code:
<tag>Ich bin m&uumlaut;de</tag>

info: http://www.xml.com/pub/a/2001/01/31/qanda.html
Back to top
View user's profile Send private message
fschofer
PostPosted: Mon May 29, 2006 7:28 am Post subject: Reply with quote

Knight

Joined: 02 Jul 2001
Posts: 524
Location: Mainz, Germany

Hi,

give this a try (untested)

Code:
DECLARE myString CHARACTER CAST(ASBITSTREAM(OutputRoot.XMLNS OPTIONS RootBitStream CCSID InputRoot.MQMD.CodedCharSetId ENCODING InputRoot.MQMD.Encoding) AS CHARACTER CCSID InputRoot.MQMD.CodedCharSetId ENCODING InputRoot.MQMD.Encoding);


Greetings
Frank
Back to top
View user's profile Send private message Send e-mail
SABCAS
PostPosted: Mon May 29, 2006 9:28 pm Post subject: Reply with quote

Acolyte

Joined: 09 Mar 2005
Posts: 60
Location: Switzerland

Hallo Frank,
Super!!! It's working, I don't know why I have make two times the same conversion, but it's working. Here is it the result
(0x03000000):XmlString = '<?xml version="1.0" encoding="UTF-8"?><ServiceLocation xmlns="urn:www.swisscom.ch/P3NIB.Web.Service/NewInstalledBaseV2/ModifyServiceLocation" Phone="890000001"><NrWires>001</NrWires><TType>001</TType><SpeedProfileNrAccess>002</SpeedProfileNrAccess><OPStatus>003</OPStatus><ContractedServices><ContractedServiceChangeIsp ContrEleId="13" IspId="100077"><ContrEleIdNew>13</ContrEleIdNew><IspIdNew>100054</IspIdNew><CustomerClass>002</CustomerClass><LevelOfSupport>001</LevelOfSupport><ModemOwner>003</ModemOwner><SpeedProfileNrService>201</SpeedProfileNrService><SpeedProfileShapingDown>1200</SpeedProfileShapingDown><SpeedProfileShapingUp>200</SpeedProfileShapingUp><SessionType>002</SessionType><Mutation>006</Mutation><ExternalRef>Ref_müde</ExternalRef></ContractedServiceChangeIsp></ContractedServices></ServiceLocation>'

Thanks a lot and have a nice day
and thanks an everybody for the Help javascript:emoticon('')
javascript:emoticon('')
Ciao
Sabato javascript:emoticon('')
javascript:emoticon('')
Back to top
View user's profile Send private message
Trugga
PostPosted: Fri Jun 02, 2006 5:38 am Post subject: Reply with quote

Novice

Joined: 30 Mar 2006
Posts: 15
Location: West Midlands (UK)

We are experiencing a similar issue, with MQ 2.1

Optiva (NT) produces an XML file, which is processed through MQ (AIX) which in turn is sent to SAP R/3 (AIX)

We are unable to reliably get extended characters from Optiva to SAP through MQ – ie, É becomes #.

Having spoken to Optiva, they have suggested the use of a Unicode conversion program.

Here are some scenarios we've tried:

1. Optiva XML (no É) -> Batch Connector -> MQ (eSQL logic drops data, due to interpretation of data which Returns False)
2. Optiva XML (no É) -> convunicode.exe -> Batch Connector -> MQ -> SAP (= OK)
3. Optiva XML (with an É) -> Batch Connector -> MQ ->DLQ
4. Optiva XML (with an É) -> convunicode.exe ->Batch Connector -> MQ -> SAP (É become #)

DLQ message from scenario 3:
Code:
DLH ........................................................................................................"...µ...MQSTR   ....\TDMS\bin\IFFTDMS_XECOUT.exe2006060110531984CSExceptionHeader   11511520060601Q.APLNTS01.1                                      \TDMS\bin\IFFTDMS_XECOUT.exe                      **Check MQRFH for identity of interface**                                                                                                                                                                                                                            000                                                                                                                                                                                                                                                                 ÿþ<

Our work around is based on scenario 2 by ensuring that no extended character set characters exist in the the Optiva data – very difficult considering the international components of our business.

The message flow looks like this:

Q – PreFlow - Q - Flow – Q

Should we be looking at the CSID's of the input notes or making amendments within the code to elliviate this issue.

Any help or pointers would be appreciated

Lawrence
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Fri Jun 02, 2006 5:47 am Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

I really hope you mean MQSI 2.1 and not MQ 2.1.

Even then, you're going to go out of Support in September, so you should be pushing to migrate to v6 as hard as you can.

If you really mean MQ 2.1, then... man. You're so far out of support it boggles my mind. Please upgrade to at least 5.3!

If you are having trouble moving international characters, it's likely that the batch connector tool is not producing the messages correctly and identifying them in a CCSID that properly represents the message data. Or it is, and everything is working the way it is supposed to - but you didn't realize that converting the data would change your É to an #.

So, yeah. Look at the CCSIDs, look at the conversion tables.

The second place to look is at the Batch Connector, and the first thing I would try is seeing if I can set the Format on the data to MQFMT_NONE instead of MQFMT_STRING. That will prevent MQ from doing any character conversion.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Trugga
PostPosted: Fri Jun 02, 2006 5:56 am Post subject: Reply with quote

Novice

Joined: 30 Mar 2006
Posts: 15
Location: West Midlands (UK)

Cheers Jeff.

Er, yes, I meant MQSI 2.1

We are aware of the support issue and have recently built a couple of v6 test boxes to assist in the evaluation of costing for the migration process.

Anyway, I thought our issue might be to do with the CCSID, but wanted a little confirmation before investigating down that particular route, which now appears to be a little different to the issue SABCAS experienced above. I was not aware of the MQFMT - I'll have a look there as well.

Cheers
Lawrence
Back to top
View user's profile Send private message
Display posts from previous:
Post new topicReply to topic Page 1 of 1

MQSeries.net Forum IndexGeneral IBM MQ SupportProblem with Encoding characters set
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.