If your backend database supports it, then CFQUERYPARAM implements bind
variables for your query.

Consider:

"select * from emp where id = #variable#"
if you execute this for employee 1, 2, 3, etc, then:

- without bind variables, the db will reparse the statement each and
every time, because the string "select * from emp where id = 1" is not
the same as the string "select * from emp where id = 2"
- with bind variables, the db will only parse the statement the first
time it sees it, then reuse the parsed query plan for subsequent runs.

Failure to use bind variables is the number one impediment to
scalability in database backed applications.

/t

>-----Original Message-----
>From: Michael Dinowitz [mailto:[EMAIL PROTECTED] 
>Sent: Tuesday, February 15, 2005 6:26 PM
>To: CF-Talk
>Subject: CFQUERYPARAM in CFC?
>
>Personally, I see no reason for a CFQUERYPARAM being used 
>inside a CFC. It adds extra overhead and the protection that 
>it provides should be provided instead by the CFARGUMENT tag. 
>Does anyone see a reason for it in such a case? Data binding? 
>
>

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Find out how CFTicket can increase your company's customer support 
efficiency by 100%
http://www.houseoffusion.com/banners/view.cfm?bannerid=49

Message: http://www.houseoffusion.com/lists.cfm/link=i:4:194817
Archives: http://www.houseoffusion.com/cf_lists/threads.cfm/4
Subscription: http://www.houseoffusion.com/lists.cfm/link=s:4
Unsubscribe: 
http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4
Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

Reply via email to