D
Diane
Hi All,
Generic question about performance and best practices:
I have code that in many places runs a lot of queries.
Is it better to run queries using the DoCmd function:
DoCmd.OpenQuery "qRunAQuery"
Or define the actual SQL statements...
' Define two SQL statements for action queries.
strSQLChange = "UPDATE Employees SET Country = " & _
"'United States' WHERE Country = 'USA'"
strSQLRestore = "UPDATE Employees SET Country = " & _
"'USA' WHERE Country = 'United States'"
Thanks,
Diane
Generic question about performance and best practices:
I have code that in many places runs a lot of queries.
Is it better to run queries using the DoCmd function:
DoCmd.OpenQuery "qRunAQuery"
Or define the actual SQL statements...
' Define two SQL statements for action queries.
strSQLChange = "UPDATE Employees SET Country = " & _
"'United States' WHERE Country = 'USA'"
strSQLRestore = "UPDATE Employees SET Country = " & _
"'USA' WHERE Country = 'United States'"
Thanks,
Diane