SoftTree Technologies SoftTree Technologies
Technical Support Forums
RegisterSearchFAQMemberlistUsergroupsLog in
Bind Variables

 
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite View previous topic
View next topic
Bind Variables
Author Message
John Natale



Joined: 13 Sep 2000
Posts: 107

Post Bind Variables Reply with quote

Hello,

I was wondering if it is possible with 24x7 scheduler to use bind variables in JAL database statements instead of hard coding values.

Example of bind variable usage:

SELECT name FROM company_list WHERE industry = :strIndustry

Example of hard coding:

SELECT name FROM company_list WHERE industry = 'BANKING'

I have only seen hard coded examples in the documentation.

Thank You

John

Fri Jan 26, 2001 6:09 pm View user's profile Send private message
SysOp
Site Admin


Joined: 26 Nov 2006
Posts: 7948

Post Re: Bind Variables Reply with quote

Not supported at this time.

But, you don't have to hard code your SQL. It can be build dynamically
like
ConcatEx "SELECT name FROM company_list WHERE industry = '", myVariable, "'", mySELECT
DatabaseRetrieve mySelect, Rows

Another option you have is to create a stored procedure that does the SELECT for you then you can use that procedure for the DatabaseRetrieve. Of course that procedure should be executed with parameters (see second paragraph above).
From your database point of view, there is a big difference as it will not cache all versions of the SELECT created by hardcoded values and thus it will speed up the SQL processing as well as provide more efficient database utilization.

: Hello,

: I was wondering if it is possible with 24x7 scheduler to use bind variables
: in JAL database statements instead of hard coding values.

: Example of bind variable usage: SELECT name FROM company_list WHERE industry
: = :strIndustry

: Example of hard coding: SELECT name FROM company_list WHERE industry =
: 'BANKING'

: I have only seen hard coded examples in the documentation.

: Thank You

: John

Fri Jan 26, 2001 6:25 pm View user's profile Send private message
Display posts from previous:    
Reply to topic    SoftTree Technologies Forum Index » 24x7 Scheduler, Event Server, Automation Suite All times are GMT - 4 Hours
Page 1 of 1

 
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


 

 

Powered by phpBB © 2001, 2005 phpBB Group
Design by Freestyle XL / Flowers Online.