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 » LocalEnvironment Variables in Mapping node

Post new topic  Reply to topic
 LocalEnvironment Variables in Mapping node « View previous topic :: View next topic » 
Author Message
gs
PostPosted: Tue Oct 01, 2013 7:19 am    Post subject: LocalEnvironment Variables in Mapping node Reply with quote

Master

Joined: 31 May 2007
Posts: 254
Location: Sweden

I'm mapping a field from the input message to the LocalEnvironment Variables using the mapping node. This since I need the value after a SOAP request.
In the output local environment I cast /LocalEnvironment/Variables/any to the input field called Name that I need to keep.
Then I "move" the input element to the name element.

Going through the debugger it all looks fine until I try to access the value from a Compute node.

After the following code line, myVariable is empty:
Code:
DECLARE myVariable CHARACTER InputLocalEnvironment.Variables.Name;


After this following code line, a new Name element is created under Variables:
Code:
SET OutputLocalEnvironment.Variables.Name = 'FOO';


I'd expect the second code line to modify the existing element.
It seems I'm accessing the Name variable in the wrong way in my code, do I need to do it another way?

Thanks!

WMB 8.0.0.1
Toolkit 8.0.0.201
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Oct 01, 2013 12:11 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

I have two things to say about this.
1. Trace node(s)
2. User trace
_________________
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
View user's profile Send private message
gs
PostPosted: Tue Oct 01, 2013 12:14 pm    Post subject: Reply with quote

Master

Joined: 31 May 2007
Posts: 254
Location: Sweden

Thanks, I've tried the trace node already but it only records the message or parts of it (not LocalEnv). I'll try again with the User Trace.
Back to top
View user's profile Send private message
Vitor
PostPosted: Tue Oct 01, 2013 12:48 pm    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

gs wrote:
I've tried the trace node already but it only records the message or parts of it (not LocalEnv).


Really? Even if you specify ${LocalEnvironment.Variables}?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
kimbert
PostPosted: Tue Oct 01, 2013 3:47 pm    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
I've tried the trace node already but it only records the message or parts of it (not LocalEnv).
What's stopping you from reading the info center : http://pic.dhe.ibm.com/infocenter/wmbhelp/v9r0m0/topic/com.ibm.etools.mft.doc/ac04840_.htm
_________________
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
View user's profile Send private message
gs
PostPosted: Tue Oct 01, 2013 9:44 pm    Post subject: Reply with quote

Master

Joined: 31 May 2007
Posts: 254
Location: Sweden

kimbert wrote:
Quote:
I've tried the trace node already but it only records the message or parts of it (not LocalEnv).
What's stopping you from reading the info center : http://pic.dhe.ibm.com/infocenter/wmbhelp/v9r0m0/topic/com.ibm.etools.mft.doc/ac04840_.htm


What leads you to believe that I haven't read the infocenter section on the Trace node?
Integration Bus v9 infocenter (that you linked) explicitly mentions $LocalEnvironment while infocenter 8 only mentions the message and its parts. Great that the v9 documentation has been updated to be clearer on this.
Back to top
View user's profile Send private message
gs
PostPosted: Tue Oct 01, 2013 11:51 pm    Post subject: Reply with quote

Master

Joined: 31 May 2007
Posts: 254
Location: Sweden

Thanks for the tip on tracing the LocalEnvironment, every day you learn something new.
It turned out that the Name element belonged to a namespace due to me casting it from the input message. I created a small schema to include a non-namespace simple string element and casted to that instead.
Now it works just fine, thanks!
Back to top
View user's profile Send private message
kimbert
PostPosted: Wed Oct 02, 2013 12:13 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
What leads you to believe that I haven't read the infocenter section on the Trace node?
Integration Bus v9 infocenter (that you linked) explicitly mentions $LocalEnvironment while infocenter 8 only mentions the message and its parts.
Fair comment - I should have checked the v8 info center. Apologies for that.
_________________
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
View user's profile Send private message
kimbert
PostPosted: Wed Oct 02, 2013 12:13 am    Post subject: Reply with quote

Jedi Council

Joined: 29 Jul 2003
Posts: 5542
Location: Southampton

Quote:
What leads you to believe that I haven't read the infocenter section on the Trace node?
Integration Bus v9 infocenter (that you linked) explicitly mentions $LocalEnvironment while infocenter 8 only mentions the message and its parts.
Fair comment - I should have checked the v8 info center. Apologies for that.
_________________
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
View user's profile Send private message
rekarm01
PostPosted: Wed Oct 02, 2013 1:56 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

gs wrote:
... while infocenter 8 only mentions the message and its parts.

v8 also has other examples, such as here and here.
Back to top
View user's profile Send private message
lancelotlinc
PostPosted: Wed Oct 02, 2013 3:04 am    Post subject: Reply with quote

Jedi Knight

Joined: 22 Mar 2010
Posts: 4941
Location: Bloomington, IL USA

gs wrote:
What leads you to believe that I haven't read the infocenter section on the Trace node?


Because your statements indicate you lack knowledge. Trace node functionality as currently implemented (AFAIK) has not changed since V6.1 with regard to what pattern you can use.

kimbert was correct and on-target when he asked you about reading the InfoCentre.
_________________
http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » LocalEnvironment Variables in Mapping node
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.