|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
DFDL Parser Adding Leading characters to Output Message. |
« View previous topic :: View next topic » |
Author |
Message
|
bkastl |
Posted: Thu Jun 05, 2014 5:54 am Post subject: DFDL Parser Adding Leading characters to Output Message. |
|
|
Newbie
Joined: 05 Jun 2014 Posts: 1
|
I am using the file input node to pick up a csv text file and
parse it with the dfdl parser. I then want to take the message and
insert it into my database with the database node.
But for some reason I am getting three leading characters(right arrows)
before my first column's data. I am using UTF-8.
The message is starting out on a Windows file directory and is picked up
by broker which is on a linux box. Any suggestions on how to remove the characters or fix this issue.
Thanks! |
|
Back to top |
|
 |
kimbert |
Posted: Thu Jun 05, 2014 6:39 am Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
If the input file is in UTF-8 then it may well start with a 'Unicode signature'. The right arrows are probably just the default character that your editor displays for unmappable characters.
If I'm right then you can model the Unicode Signature as an optional field at the start of the message.
- Create an optional element called 'UnicodeSignature'. Set its initiator to "%#rEF;%#rBB;%#rBF;".
- Set its length to 0
- Do not map this optional field to the output tree _________________ 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 |
|
 |
zpat |
Posted: Thu Jun 05, 2014 6:42 am Post subject: |
|
|
 Jedi Council
Joined: 19 May 2001 Posts: 5866 Location: UK
|
Is it the BOM (Byte Order Mark)?
.Net tends to do this, change the code to write as ASCII to avoid it. _________________ Well, I don't think there is any question about it. It can only be attributable to human error. This sort of thing has cropped up before, and it has always been due to human error. |
|
Back to top |
|
 |
kimbert |
Posted: Thu Jun 05, 2014 12:53 pm Post subject: |
|
|
 Jedi Council
Joined: 29 Jul 2003 Posts: 5542 Location: Southampton
|
No, it's like a BOM, but UTF-8 does not need any 'byte order', so the correct name is 'Unicode Signature'.
Quote: |
change the code to write as ASCII to avoid it |
That sounds like dangerous advice, unless you know a lot more about the OP's message flow than we do. What should the OP do if the file needs to contain non-ASCII characters? _________________ 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 |
|
 |
|
|
 |
|
Page 1 of 1 |
|
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
|
|
|
|