Would I get better performance by either embedding a SQL statement into a DoCmd.RunSQL statement or by calling up a query with a DoCmd.OpenQuery?
TIA, Ari
If you save the query either as a query object or in the recordsource property of a form or a report, Jet will build a query plan the first time it is used, speeding performance on subsequent uses. A bit. If you do it in code, the plan has to be built every time the query is used. In most cases the difference is pretty small. In some cases I'll be willing to suffer a bigger hit because it gives me the ability to build the sql on the fly, in the code.
Jeremy =============
Jeremy Wallace
Designing, Developing, and Deploying Access Databases Since 1995
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.