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 » Move a reference to a variable

Post new topic  Reply to topic
 Move a reference to a variable « View previous topic :: View next topic » 
Author Message
lillo
PostPosted: Thu Jun 13, 2002 11:53 pm    Post subject: Move a reference to a variable Reply with quote

Master

Joined: 11 Sep 2001
Posts: 224

Hi,

I would like to move a reference variable to the content of another variable. Is this possible?

Let see an example:

DECLARE ref REFERENCE TO OutputRoot.XML

SET OutputRoot = InputRoot;
SET Environment.Field = 'FieldA';

I need the referencie to point to OutputRoot.XML.FieldA, So I tried

EVAL ('MOVE ref TO ref' || Environment.Field)

but it doesn´t work, any idea?

thanks

Lillo
Back to top
View user's profile Send private message
kirani
PostPosted: Fri Jun 14, 2002 7:46 am    Post subject: Reply with quote

Jedi Knight

Joined: 05 Sep 2001
Posts: 3779
Location: Torrance, CA, USA

Lillo,

You cannot reference to something which doesn't exist! In your code you are trying to create a reference to some field in Output tree but your output tree is created below it.

You should rearrange your statements as follows,

Code:

SET OutputRoot = InputRoot;
DECLARE ref REFERENCE TO OutputRoot.XML

SET Environment.Field = 'FieldA';
EVAL ('MOVE ref TO ref.' || Environment.Field)


Remember, EVAL is an expensive operation. You can implement the same using Reference Variable and MOVE, LASTMOVE, FIELDNAME, ..

Regards,
_________________
Kiran


IBM Cert. Solution Designer & System Administrator - WBIMB V5
IBM Cert. Solutions Expert - WMQI
IBM Cert. Specialist - WMQI, MQSeries
IBM Cert. Developer - MQSeries

Back to top
View user's profile Send private message Visit poster's website
lillo
PostPosted: Sun Jun 16, 2002 12:51 am    Post subject: Reply with quote

Master

Joined: 11 Sep 2001
Posts: 224

Thanks for your reply, but what is more expensive use the eval function or search for different tags in the xml tree using the reference?

Thanks in advance

Lillo
_________________
Lillo
IBM Certified Specialist - WebSphere MQ
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 » Move a reference to 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.