You could try it, but your probably right creating a new instance every time
might be slower.

 

However if you create an instance of the SQL object at application level,
this might be even quicker than inline as it's already in the server's
memory.

 

<cfset application.sql = createObject('component', 'com.company.sql.Sql') />

 

 

Then from any page you could do something like

 

<cfset resultQuery = application.sql.executeSp('spName') />

 

etc

 

Regards
Dale Fraser

 

  _____  

From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf
Of Taco Fleur
Sent: Monday, 29 January 2007 6:18 PM
To: [email protected]
Subject: [cfaussie] putting queries in cfcs or not....

 

We are working on an application that will receive high traffic.

 

All queries are Stored Procedures (MS SQL 2005) and I was thinking of
putting all the calls to those SPs in a CFC, only to keep all the SQL in one
place. But since I am more concerned about speed than anything else, I am
thinking this might not be the best way to go. 

 

I am leaning more towards putting the calls to the stored procedures inline
the code now. Any input on this is much appreciated.

-- 
Taco Fleur - http://www.pacificfox.com.au 
Web Design, Web development, Graphic Design and Complete Internet Solutions
an industry leader with commercial IT experience since 1994 . 




--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cfaussie" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cfaussie?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to