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 » Fieldname question

Post new topic  Reply to topic
 Fieldname question « View previous topic :: View next topic » 
Author Message
schroederms
PostPosted: Wed Mar 12, 2008 12:28 pm    Post subject: Fieldname question Reply with quote

Disciple

Joined: 21 Jul 2003
Posts: 169
Location: IA

I'm trying to get the tag name after the R3 tag, thought this should work, but it is acting like it does not exist.

Set Environment.Temp.Tagname = Fieldname(InputBody.REQUEST.APP.R3.*[1]);
set OutputRoot.XML.[1] NAME = Environment.Temp.Tagname;

Thanks.

Here is the input XML;
REQUEST
REQUEST.CONTROL
REQUEST.CONTROL.ORIGINATOR='O2O'
REQUEST.CONTROL.ORIGIN_DATETIME='Wed Mar 12 10:58:01 CDT 2008'
REQUEST.CONTROL.SERVICE='R3'
REQUEST.CONTROL.FUNCTION='Z_RFC_121_PARTNER_PLANT_LIST'
REQUEST.CONTROL.DESTINATION
REQUEST.CONTROL.DESTINATION.INSTANCE='DV3'
REQUEST.CONTROL.DESTINATION.CLIENT='120'
REQUEST.CONTROL.VERSION='1.0'
REQUEST.CONTROL.PERSISTENCE='N'
REQUEST.CONTROL.REALTIME='Y'
REQUEST.CONTROL.AUDIT_LOG='Y'
REQUEST.CONTROL.ROUTER_MSGTIMES
REQUEST.CONTROL.ROUTER_MSGTIMES.GMTMSGSTART='2008-03-12 15:58:01.165878'
REQUEST.CONTROL.ROUTER_MSGTIMES.GMTMSGCOMPLETION='2008-03-12 15:58:01.165878'
REQUEST.APP
REQUEST.APP.R3
REQUEST.APP.R3.ZSD_121_PLANT_IN
REQUEST.APP.R3.ZSD_121_PLANT_IN.item
REQUEST.APP.R3.ZSD_121_PLANT_IN.item.SALES_ORG='1900'
REQUEST.APP.R3.ZSD_121_PLANT_IN.item.DIST_CHL='40'
REQUEST.APP.R3.ZSD_121_PLANT_IN.item.DIVISION='10'
REQUEST.APP.R3.ZSD_121_PLANT_IN.item.SHIP_TO='1010005266'
REQUEST.STATUS
REQUEST.STATUS.CODE='0'
REQUEST.STATUS.DESCRIPTION='SUCCESSFUL'
Back to top
View user's profile Send private message
chrisc
PostPosted: Wed Mar 12, 2008 1:51 pm    Post subject: Reply with quote

Voyager

Joined: 19 Mar 2006
Posts: 77

From memory, InputBody (which is the equivalent of InputRoot.XML in your case) actually refers to the root element of your XML, not to some imaginary element above this.

So I think your statement should be:
Code:
Set Environment.Temp.Tagname = Fieldname(InputBody.APP.R3.*[1]);


Last edited by chrisc on Wed Mar 12, 2008 2:03 pm; edited 1 time in total
Back to top
View user's profile Send private message
marcin.kasinski
PostPosted: Wed Mar 12, 2008 2:02 pm    Post subject: Re: Fieldname question Reply with quote

Sentinel

Joined: 21 Dec 2004
Posts: 850
Location: Poland / Warsaw

schroederms wrote:
I'm trying to get the tag name after the R3 tag, thought this should work, but it is acting like it does not exist.

Set Environment.Temp.Tagname = Fieldname(InputBody.REQUEST.APP.R3.*[1]);
set OutputRoot.XML.[1] NAME = Environment.Temp.Tagname;


You can "debug" it:

Set Environment.A1 = Fieldname(InputBody);
Set Environment.A2 = Fieldname(InputBody.REQUEST);
Set Environment.A3 = Fieldname(InputBody.REQUEST.APP);
Set Environment.A4 = Fieldname(InputBody.REQUEST.APP.R3);
Set Environment.A5 = Fieldname(InputBody.REQUEST.APP.R3.*[1]);

Which Ax fields are not null ?
_________________
Marcin
Back to top
View user's profile Send private message Visit poster's website
kimbert
PostPosted: Wed Mar 12, 2008 2:27 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Please don't use the XML domain for new message flows - it is deprecated. Please use XMLNSC.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Fieldname question
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.