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 Index » WebSphere Message Broker (ACE) Support » XML mapping using single line of ESQL

Post new topic  Reply to topic
 XML mapping using single line of ESQL « View previous topic :: View next topic » 
Author Message
zico
PostPosted: Mon Nov 13, 2006 5:31 pm    Post subject: XML mapping using single line of ESQL Reply with quote

Novice

Joined: 22 Jun 2005
Posts: 21

Hello,

I have following XML msg coming in :

<?xml version="1.0" encoding="utf-8" ?>
<Billing>
<Code>A001</Code>
<Desc>Bill Of Matrial</Desc>
</Billing>

Expected output msg has be to like:

<?xml version="1.0" encoding="utf-8" ?>
<Customer>
<Info>
<Type>PO</Type>
</Info>
<Billing>
<Code>A001</Code>
<Desc>Bill Of Matrial</Desc>
</Billing>
</Customer>

To generate above output, I want to set the mapping for Billing segment under Customer in one line but it does not generate the proper output using following code:

Set InputRoot.XML.Customer.Info.Type = 'PO';
Set InputRoot.XML.Customer.Billing.*[] = InputRoot.XML.Billing.*[];


Can anyone help to the write shortcut method where same source xml structure has to be attach in some part of the output xml instead of mapping element wise.

Thanks in advance.
Zico
Back to top
View user's profile Send private message
msukup
PostPosted: Mon Nov 13, 2006 6:57 pm    Post subject: Reply with quote

Acolyte

Joined: 11 Feb 2002
Posts: 56

Part of your problem is that you need to set OutputRoot rather than InputRoot. Try:

SET OutputRoot.XML.Customer.Billing = InputRoot.XML.Billing;

That will copy the tree from Billing down -- skip the brackets and star, they don't buy you anything in this case.

You should revisit the line before the one you highlighted in red, too.
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » XML mapping using single line of ESQL
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.