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 » Help needed in Mapping node IIB9.0.0.2

Post new topic  Reply to topic
 Help needed in Mapping node IIB9.0.0.2 « View previous topic :: View next topic » 
Author Message
Armageddon123
PostPosted: Mon Aug 31, 2015 11:07 am    Post subject: Help needed in Mapping node IIB9.0.0.2 Reply with quote

Acolyte

Joined: 11 Feb 2014
Posts: 61

Hi All,

I am facing an issue with graphical mapping node.

mapping node has options to add logic to transform the request element using if,else,concact etc functions before calling an ESQL function in mapping node.
But The requirement is- not to output the element when the output value is say 'a' or 'c'. Since I was not able to do the same in mapping logic, we added that logic in a next compute node. But the architect has rejected this code saying that just for few such logics, we should not be using an extra compute node.

Can you please advise what method we have in mapping node, where based on the output , we can perform additional transformation, if any,
I cant really see where it can be done

Thanks.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Mon Aug 31, 2015 11:40 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

Don't wire an output from the relevant else blocks.
_________________
chmod -R ugo-wx /
Back to top
View user's profile Send private message
Armageddon123
PostPosted: Mon Aug 31, 2015 1:56 pm    Post subject: Reply with quote

Acolyte

Joined: 11 Feb 2014
Posts: 61

hi mqjeff,

thanks,

but in mapping node, if, else logics are only applicable for the request element. here I would like to appy same if else logic to the response element just before assigning to the output element.

Example:

if($abc=condition)
call esql function
else
call another esql function

Now, this function is having an output which I need to check and act accordinly

if $output='a'
dont wire to output element
else
wire to output element



But we dont have anything like $output avaible in mapping node. since we are not able to apply any logic on the output variable.(variables are only present for the input side), we are not able to proceed with this method
Back to top
View user's profile Send private message
Vitor
PostPosted: Mon Aug 31, 2015 2:57 pm    Post subject: Re: Help needed in Mapping node IIB9.0.0.2 Reply with quote

Grand High Poobah

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

Armageddon123 wrote:
But the architect has rejected this code saying that just for few such logics, we should not be using an extra compute node.


I'd ask the architect what design he feels would allow this to be rolled into the compute node. As he clearly has something in mind, or at least thinks he has, or is just blowing smoke.....
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
martinb
PostPosted: Tue Sep 01, 2015 1:44 am    Post subject: Reply with quote

Master

Joined: 09 Nov 2006
Posts: 210
Location: UK

There are a couple of ways the Graphical Mapper can achieve your ESQL function with it's "don't call me if my output will not be what you want" behavior

Option 1
Detect what input value would cause this unwanted output and don't call it in that case


Option 2
- Have your output target element defined as nillable
- Wrapper your existing ESQL function in another ESQL which will flip a unwanted return value into a NULL

Option 3
Actually call this ESQL function as part of your If condition .. and then call it again if the output is acceptable to be passed to the output

If <esql>funcWithPosBadReturn($input) != 'bad'
$ouput = <esql>funcWithPosBadReturn($input)

.. inefficient having to call twice, but a smaller hammer than a follow on compute node to delete the unwanted output after the Mapping node

Note: When you include a Custom ESQL transform, an import is added to refer to the ESQL file, defining a prefix based on the file name. If you need to use custom ESQL only in condition or filter expressions, you can use the "ESQL Imports" properties of the map to add ESQL imports to an ESQL file so that the applicable modules are available through content assist when you are composing an expression.
Back to top
View user's profile Send private message
Armageddon123
PostPosted: Tue Sep 01, 2015 9:17 am    Post subject: Reply with quote

Acolyte

Joined: 11 Feb 2014
Posts: 61

Hi Martinb

Thankyou for the options. hopefully, I will be able to proceed with options 2 or 3.
i will also try to raise an RFE to include this option also in mapping node- "capability to apply logic on the output element before exiting mapping node".

Thanks
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 » Help needed in Mapping node IIB9.0.0.2
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.