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 » ESQL Variable Substitution

Post new topic  Reply to topic
 ESQL Variable Substitution « View previous topic :: View next topic » 
Author Message
Dave Ziegler
PostPosted: Tue Feb 10, 2015 3:45 pm    Post subject: ESQL Variable Substitution Reply with quote

Centurion

Joined: 15 Apr 2014
Posts: 118

I'm having trouble locating the correct syntax to substitute the 5 in this line of ESQL with an external variable. I can't just put the variable name in place of the 5, and the {curly_brace} trick doesn't work here.

Code:
CREATE LASTCHILD OF n NAME 'StartTime' VALUE CURRENT_TIME + INTERVAL '5' MINUTE;


Help?
Back to top
View user's profile Send private message
rekarm01
PostPosted: Tue Feb 10, 2015 10:32 pm    Post subject: Re: ESQL Variable Substitution Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

Dave Ziegler wrote:
I'm having trouble locating the correct syntax to substitute the 5 in this line of ESQL with an external variable. I can't just put the variable name in place of the 5, and the {curly_brace} trick doesn't work here.

Integer multiplication should work with INTERVALs:

Code:
CREATE LASTCHILD OF n NAME 'StartTime' VALUE CURRENT_TIME + ExternalVariable * INTERVAL '1' MINUTE;
Back to top
View user's profile Send private message
Dave Ziegler
PostPosted: Wed Feb 11, 2015 5:24 am    Post subject: Reply with quote

Centurion

Joined: 15 Apr 2014
Posts: 118

Good call, I will try this. I was making it too difficult.

Thanks...
Back to top
View user's profile Send private message
mqjeff
PostPosted: Wed Feb 11, 2015 5:50 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

You could maybe use CAST as well, to turn the variable into an interval.
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 » ESQL Variable Substitution
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.