D
deko
I came across this MSDN article
http://msdn2.microsoft.com/en-us/library/bb177500.aspx and was wondering if
anyone has had any luck with it:
Dim db as DAO.Database
Set db = CurrentDb
Set qdf = db.CreateQueryDef("")
strSql = [dynamically created SQL]
qdf.SQL = strSql
qdf.Execute dbFailOnError
Set qdf = Nothing
Is this a better alternative to:
strSql = [dynamically created SQL]
db.Execute strSql, dbFailOnError
Either way, Access has to compile the query before running it, correct?
Any thoughts?
http://msdn2.microsoft.com/en-us/library/bb177500.aspx and was wondering if
anyone has had any luck with it:
Dim db as DAO.Database
Set db = CurrentDb
Set qdf = db.CreateQueryDef("")
strSql = [dynamically created SQL]
qdf.SQL = strSql
qdf.Execute dbFailOnError
Set qdf = Nothing
Is this a better alternative to:
strSql = [dynamically created SQL]
db.Execute strSql, dbFailOnError
Either way, Access has to compile the query before running it, correct?
Any thoughts?