Here is the skinny. A stored procedure is faster than an inline query because it is precompiled on the database and most databases make 'plans' on the fastest way to execute the query.
A view is compiled as well. However when you query a view it executes the view's sql then it executes your sql on the returned results. So essentialy a stored procedure calling a view is like running a stored proc on a stored proc. Now a materialized view (or snapshot) is _executed_ on set intervals or manually and actually physically creates a table. So when you run a stored procedure on a materialized view, you are essentialy only running a single SQL procedure. -Adam On Tue, 18 Jan 2005 06:35:42 -0400, Will Tomlinson <[EMAIL PROTECTED]> wrote: > With everyone's help I'm pretty much wrapping up the functionality of my > clothing app/SQL Server db. I was planning on converting much of my SELECT > <cfquery>s to stored procedures, and started reading some about views. Is a > view equal to a stored procedure in performance? Does it matter at all which > you use? Is one easier than the other? > > I'm trying to keep the load off of CF and place it on SQL Server since I'm > using shared hosting. > > Thanks, > > Will > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Logware: a new and convenient web-based time tracking application. Start tracking and documenting hours spent on a project or with a client with Logware today. Try it for free with a 15 day trial account. http://www.houseoffusion.com/banners/view.cfm?bannerid=67 Message: http://www.houseoffusion.com/lists.cfm/link=i:4:190972 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=89.70.4 Donations & Support: http://www.houseoffusion.com/tiny.cfm/54

