> The code I sent was just to illustrate the fact that no matter how > optimized the code is within a cfc, there is a minimum amount of time > a cfc is going to take to execute.
Right - and this is to be expected. > Specifically what I was trying to optimize was a check to see of an > email address was a duplicate, valid, and not in a remove list. This > would require 2 database queries and a run through the validate > method. I eliminated the need for the two queries by using query of > queries, but was unable to get barely any performance gain...every cfc > call is taking ~15ms, no matter what. 15ms seems a bit high. However, remember that the point here is encapsulation. By having your 'isDupe' method stored in one central location, you can easily update the code w/o worrying about other templates that may have had their own versions. You could also add security. I won't go on - I love CFCs and it's obvious. The point remains the same. The _fastest_ code will almost always be inline code. However, speed isn't everything. -ray ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Get the mailserver that powers this list at http://www.coolfusion.com

