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 » WMB mapping node...

Post new topic  Reply to topic
 WMB mapping node... « View previous topic :: View next topic » 
Author Message
sirsi
PostPosted: Thu Dec 14, 2006 4:53 am    Post subject: WMB mapping node... Reply with quote

Disciple

Joined: 11 Mar 2005
Posts: 177

Hi ,

How can i refer to $target elements in the mapping node.(WBM toolkit v6 fixpack 02)
eg:-
My output message is like this.
$target
Msg
|_element1
|_element2
how can i set element2 = element1 in the mapping sheet.
element2 = $target/Msg/element1 .. is giving error...
But the same is working in WBIMB mapping node.

let me know if i am not clear.

Thanks
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Thu Dec 14, 2006 5:23 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

You're entirely unclear.

You have an error.

What is the error message?
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
sirsi
PostPosted: Fri Dec 15, 2006 2:34 am    Post subject: Reply with quote

Disciple

Joined: 11 Mar 2005
Posts: 177

In the mapping node i am assigning element2 the value of element1..

element1 == $source/Src/element1 ( mapped from source element1)
element2 == $target/Msg/element1 ( mapped from element1 of target message).

i am getting error at the element2 mapping... and error is "$target is out of scope".

How can i refer to element1 of target message so that i can assign the same value to the element2.
Back to top
View user's profile Send private message
fjb_saper
PostPosted: Fri Dec 15, 2006 3:42 am    Post subject: Reply with quote

Grand High Poobah

Joined: 18 Nov 2003
Posts: 20756
Location: LI,NY

Have you tried:
element1 == $source/Src/element1 ( mapped from source element1)
element2 == $source/Src/element1 ( mapped from source element1)

?
_________________
MQ & Broker admin
Back to top
View user's profile Send private message Send e-mail
sirsi
PostPosted: Fri Dec 15, 2006 3:49 am    Post subject: Reply with quote

Disciple

Joined: 11 Mar 2005
Posts: 177

ya surely it works... but actually my mapping is not simple as that
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Dec 15, 2006 3:54 am    Post subject: Reply with quote

Grand High Poobah

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

sirsi wrote:
ya surely it works... but actually my mapping is not simple as that


Perhaps if you explained your requirement a bit more?

It's perhaps unclear why you need to take a value from the input, add it to an output element, then populate another output element with the same value but taken from the output rather than the input.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
sirsi
PostPosted: Fri Dec 15, 2006 4:08 am    Post subject: Reply with quote

Disciple

Joined: 11 Mar 2005
Posts: 177

for the element1 mapping i have applied a complex logic ( if,else )... element2 needs the same value to be populated as element1. So instead of doing the computation again i thought of using the value at element1.
Back to top
View user's profile Send private message
jefflowrey
PostPosted: Fri Dec 15, 2006 4:55 am    Post subject: Reply with quote

Grand Poobah

Joined: 16 Oct 2002
Posts: 19981

Maybe you should map your computation into Environment, instead of the output tree, and then map both target fields from environment.

Maybe you should use an ESQL procedure to compute your value, and use a SHARED variable to cache the results so you don't recompute.

Maybe you shouldn't use a Mapping node for something this complex.
_________________
I am *not* the model of the modern major general.
Back to top
View user's profile Send private message
Vitor
PostPosted: Fri Dec 15, 2006 5:08 am    Post subject: Reply with quote

Grand High Poobah

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

sirsi wrote:
for the element1 mapping i have applied a complex logic ( if,else )... element2 needs the same value to be populated as element1. So instead of doing the computation again i thought of using the value at element1.


I think it's going to be easier / faster / less stressful to store the result in a variable and populate both of the outputs from that.

Or normalise the output to remove the duplicate data item!

(easier said than done I know..)
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
sirsi
PostPosted: Fri Dec 15, 2006 6:28 am    Post subject: Reply with quote

Disciple

Joined: 11 Mar 2005
Posts: 177

But this mapping is working in WBIMB... isnt there any way to access $target elements in WMB?
Back to top
View user's profile Send private message
jfluitsm
PostPosted: Sun Jan 07, 2007 8:39 am    Post subject: Reply with quote

Disciple

Joined: 24 Feb 2002
Posts: 160
Location: The Netherlands

The mapping in V5 and V6 are completely different.
V5 mapping is procedural, what has to be mapped in wich sequence.
V6 is declarative, how should the result look.

As V6 has no guarantee for the sequence in which the mappings are processed, it is not possible to use target fields.

See the topic in the InfoCenter about migrating the mapping from V5 to V6 for incompatabilities.
_________________
Jan Fluitsma

IBM Certified Solution Designer WebSphere MQ V6
IBM Certified Solution Developer WebSphere Message Broker V6
Back to top
View user's profile Send private message Send e-mail
sirsi
PostPosted: Fri Jan 19, 2007 4:37 am    Post subject: Reply with quote

Disciple

Joined: 11 Mar 2005
Posts: 177

thanks jfluitsm... i will set those mapping outside the mapping nodes
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 » WMB 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.