Author |
Message
|
vara |
Posted: Mon Jul 08, 2013 2:39 am Post subject: How can we access Environment tree node in Mapping node? |
|
|
Newbie
Joined: 08 Jul 2013 Posts: 1
|
How can we map Environment Variable to Target fields in Mapping node. |
|
Back to top |
|
 |
lancelotlinc |
Posted: Mon Jul 08, 2013 3:21 am Post subject: Re: How can we access Environment tree node in Mapping node? |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
smdavies99 |
Posted: Mon Jul 08, 2013 3:22 am Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
This question has been asked before
The search option (upper right of the window) can return wonderful results.
Have you tried it? _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
mqjeff |
Posted: Mon Jul 08, 2013 8:23 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
|
Back to top |
|
 |
lancelotlinc |
Posted: Mon Jul 08, 2013 8:29 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
mqjeff |
Posted: Mon Jul 08, 2013 8:52 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
What happens when you try it? |
|
Back to top |
|
 |
lancelotlinc |
Posted: Mon Jul 08, 2013 9:22 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
|
Back to top |
|
 |
mqjeff |
Posted: Mon Jul 08, 2013 9:35 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
lancelotlinc wrote: |
I'm busy with IIB V9 atm. If I get around to it, I'll let you know. |
ESQL routines called from Mapping node are not called in a scope that has Environment as a defined correlation name.
So you'd have to do something horrendous like stick a reference in LocalEnvironment that pointed to Environment and then access that to get at Environment.
But it's a horrible horrible idea. |
|
Back to top |
|
 |
lancelotlinc |
Posted: Mon Jul 08, 2013 9:43 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
mqjeff wrote: |
lancelotlinc wrote: |
I'm busy with IIB V9 atm. If I get around to it, I'll let you know. |
ESQL routines called from Mapping node are not called in a scope that has Environment as a defined correlation name.
So you'd have to do something horrendous like stick a reference in LocalEnvironment that pointed to Environment and then access that to get at Environment.
But it's a horrible horrible idea. |
Does this seem like Global Cache may be a good application here? _________________ http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER |
|
Back to top |
|
 |
rekarm01 |
Posted: Mon Jul 08, 2013 10:00 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 1415
|
mqjeff wrote: |
So you'd have to do something horrendous like stick a reference in LocalEnvironment that pointed to Environment and then access that to get at Environment. |
Is that even possible, to create a message tree element with REFERENCE data type?
lancelotlinc wrote: |
Does this seem like Global Cache may be a good application here? |
Probably not. |
|
Back to top |
|
 |
mqjeff |
Posted: Mon Jul 08, 2013 10:04 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
rekarm01 wrote: |
mqjeff wrote: |
So you'd have to do something horrendous like stick a reference in LocalEnvironment that pointed to Environment and then access that to get at Environment. |
Is that even possible, to create a message tree element with REFERENCE data type? |
Dunno. Probably not. Might be able to use a SCHEMA level variable, but again it gets ugly pretty darn quick.
Again, best thing is to simply not expect to use Environment from GDM. |
|
Back to top |
|
 |
lancelotlinc |
Posted: Mon Jul 08, 2013 10:22 am Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
So the OP is left with copying whatever interested elements from Environment to LocalEnvironment before the call to mapping node?
What's the technical challenge that makes it difficult to give mapping node access to the Environment tree natively? _________________ http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER |
|
Back to top |
|
 |
mqjeff |
Posted: Mon Jul 08, 2013 10:29 am Post subject: |
|
|
Grand Master
Joined: 25 Jun 2008 Posts: 17447
|
lancelotlinc wrote: |
So the OP is left with copying whatever interested elements from Environment to LocalEnvironment before the call to mapping node? |
And back, afterwards, yes.
lancelotlinc wrote: |
What's the technical challenge that makes it difficult to give mapping node access to the Environment tree natively? |
I'm not aware. |
|
Back to top |
|
 |
martinb |
Posted: Mon Nov 16, 2015 4:48 am Post subject: |
|
|
Master
Joined: 09 Nov 2006 Posts: 210 Location: UK
|
|
Back to top |
|
 |
|