|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Problems mapping XML to ff using ESQL |
« View previous topic :: View next topic » |
Author |
Message
|
southpaw |
Posted: Mon May 05, 2008 1:33 am Post subject: Problems mapping XML to ff using ESQL |
|
|
Newbie
Joined: 04 Jul 2006 Posts: 6
|
Hi everyone,
I'm having some difficulty converting xml to a flatfile msg using ESQL(basic stuff).
The problem is this:
In my inputmsg i have the following xml:
<groups>
<groupA>
<elementA>2008-04-14</elementA>
</groupA>
<groupB>
<elementA>2008-04-14</elementA>
</groupB>
</groups>
My MRM definition(output flatfile msg) contains three date fields. Given my inputmsg i would expect that my flatfile msg would result into the following:(dates that aren't filled in the input, are defaulted to 00000000)
200804142008041400000000
But somehow i end up with:
200804142008041420080414
However, when i change the inputmsg to:
<groups>
<groupA>
<elementA>2008-04-14</elementA>
</groupA>
<groupB>
<elementA>2008-04-14</elementA>
</groupB>
<groupC/>(i.e. where the third element would be)
</groups>
it works properly and i get my expected result.
My ESQL is as follows:
DECLARE RefInput REFERENCE TO InputRoot.XML.groups;
SET OutputRoot.MRM.elementA = COALESCE(NULLIF(RefInput.groupA.elementA,''),00000000);
SET OutputRoot.MRM.elementB = COALESCE(NULLIF(RefInput.groupA.elementB,''),00000000);
SET OutputRoot.MRM.elementC = COALESCE(NULLIF(RefInput.groupC.elementC,''),00000000);
I haven't had this problem before. We just apgraded to brokerv6.0 and maybe it has something to do with that? The way ESQL is processed or something.
Any help would be greatly appreciated,
Thanx in advance,
Bas. |
|
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
|
|
|
|