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 » Setting XML element via a variable

Post new topic  Reply to topic
 Setting XML element via a variable « View previous topic :: View next topic » 
Author Message
bnewman18
PostPosted: Thu Mar 07, 2002 10:40 am    Post subject: Reply with quote

Newbie

Joined: 06 Mar 2002
Posts: 5

I was wondering if the following was possible in MQSI. I want to create a generic rules processor. Rules would be read from a database in XML that indicate an element in the message to check against a value.
<Rule>
<condition>
<element>customer</element>
<compare>EQ</compare>
<compareValue>ABC</compareValue>
<condition>
</Rule>
So the ESQL would ideally read the conditions, for each one get the element contained in the element tag of the rule. Check the compare tag with the compare value, and return true/false.
I just don't know if there's a way to specifiy a variable name as the element name in the input document. I realize the setup of the rule must match the element name in the document, but this would allow one rule node regardless of the message type. Any thoughts on this would be appreciated. Thanks.
OutputRoot.XML.
Back to top
View user's profile Send private message
amigupta1978
PostPosted: Thu Mar 07, 2002 11:33 am    Post subject: Reply with quote

Centurion

Joined: 22 Jan 2002
Posts: 132
Location: India

Hi,
Use can use the EVAL function in ESQL to do this. Declare dynamic variables in ESQL and do any type of dynamic processing. But this make ur programs slower to run at run time.
But the way u want I think can be achieved by simply using the IF THEN ELSE loop like IF InputRoot.XML.Rule.compare='EQ' THEN IF InputRoot.XML.Rule.element=InputRoot.XML.Rule.compareVale Then Set OutputRoot.XML.Rule.Result='TRUE'; ELSE SET OutputRoot.XML.Rule.Result='FALSE'
END IF; ,......ELSe....END IF;

amit

Back to top
View user's profile Send private message Send e-mail Yahoo Messenger
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Setting XML element via a variable
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.