Posted: Mon Dec 13, 2010 3:35 pm Post subject: MQ Series and EBCDIC to ASCII Conversion
Newbie
Joined: 13 Dec 2010 Posts: 1
We have a problem.
We have an application on the Mainframe that allows textual descriptions. We have a DB2 trigger that on change sends a message via MQ Series to a client server application. We have a web service that is invoked via a Tibco EMS process - from the Message on the MQ Series Queue.
We have discovered that when we recieve text containing '[' or ']' values - the fields following are displaced by a byte, and we actually see an invalid date error. We have removed the bad characters from the string and everything is fine.
My Question is this - are there any other characters in EBCDIC that will cause a similar problem. We may have to put a text scrubbing algorithm to replace the square bracket with rounded parenthesis. And I have been researching EBCDIC to ASCII conversion - but cannot find a definitive text that outlines problems and characters to avoid.
I suspect very much that you are converting before you are parsing.
And possibly converting to UTF-8.
This is problematic because you are counting in bytes for your parsing instead of counting in characters. Thus any character that converts from a single byte (EBCDIC) into multiple bytes (UTF-8 ) will cause you problems.
This is normal and expected behavior. Your suggested solution is looking at it the wrong way. Transform the UTF-8 stream into a String of characters and then parse using the # of characters in the field...
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