Author |
Message
|
Ashimashi |
Posted: Mon Apr 16, 2012 4:33 am Post subject: XML output field format |
|
|
Novice
Joined: 06 Oct 2011 Posts: 20
|
Hi,
I've tried searching about this issue of mine, but it's not the easiest question to specify. I'm trying to reformat my xml field structure ouput from:
<test>
Hello
</test>
to:
<test>Hello</test>
Does anyone know how this could be managed? Is it something on the input MRM parser side which puts line breaks at every line?
Thanks,
A |
|
Back to top |
|
 |
mqjeff |
Posted: Mon Apr 16, 2012 4:36 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
Those are two entirely separate XML fields.
The first one contains the text "<lf>Hello<lf>".
The second one contains the text "hello".
Until you have proven to yourself which of these two things the field actually holds, you haven't shown anything about Broker. It's entirely possible whatever you're using to view the XML is making it 'pretty' for you.
Also, DO NOT USE MRM FOR XML DATA OF ANY KIND. |
|
Back to top |
|
 |
Ashimashi |
Posted: Mon Apr 16, 2012 4:47 am Post subject: |
|
|
Novice
Joined: 06 Oct 2011 Posts: 20
|
Thank you jeff for the quick reply.
I'm parsing from a Tagged Delimited format using MRM. This is then mapped to a canonical xml format.. which finally is mapped to the output xml format in the XMLNSC domain.
So correct me if I'm wrong.. is it that I'm actually passing through and mapping text (cointaining field name and value) and not only the value of the field? Where in the process do you suggest this could be corrected?
//A |
|
Back to top |
|
 |
Vitor |
Posted: Mon Apr 16, 2012 4:52 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Ashimashi wrote: |
is it that I'm actually passing through and mapping text (cointaining field name and value) and not only the value of the field? Where in the process do you suggest this could be corrected? |
You still have not demonstrated that the output from the process really is the 1st form and that's not just how your XML tool is displaying it. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
mqjeff |
Posted: Mon Apr 16, 2012 4:54 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
No, I'm telling you that the content of the field contains the line feeds.
If you wish to remove them you need to alter your TDS model to remove them or you need to alter the contents of the field.
Note that there is a significant difference in XML between the following two things.
Code: |
<body>
<test>Hello</test>
</body> |
Code: |
<body><test>
Hello
</test/></body> |
You are showing the second case.
EDIT: and, again, you haven't shown that your message data is either form. You might, as my esteemed colleague reminds me, be suffering from a presentation tool issue. |
|
Back to top |
|
 |
Ashimashi |
Posted: Mon Apr 16, 2012 5:10 am Post subject: |
|
|
Novice
Joined: 06 Oct 2011 Posts: 20
|
You guys are totally right. I'm using mqmon to view the output. I toggled the view option to hex to see if I actually had line breaks. Well, I didn't. I viewed a correct formated xml, that I had from earlier, in mqmon.. and the result was line breaks. So the issue was indeed the presentation tool.
Thank you for pointing me in the right direction.
//A |
|
Back to top |
|
 |
|