Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

When to use ADO, and DAO?

Status
Not open for further replies.

seaport

MIS
Jan 5, 2000
923
US
I started using ADO as the primary data access tool when Access 2000 came out, without putting much thought into it. Now I am thinking about whether I've been doing it right.

I read the thread "DAO vs ADO" ( but still have more questions.

Here are different scenarios. (This discussion does not cover Access 2007, which I know nothing about).

Accessing/Updating local/linked mdb tables – definitely DAO, which is designed for Access Jet.

Regarding SQL Server
1. Accessing/Updating remote tables in SQL Server – I feel like using ADO
2. Accessing/Updating ODBC linked SQL tables – my guess is that DAO performs better than ADO, since Jet is handling the linked table anyway.
3. Calling stored procedures – ADO seems to be the better option because of the ADODB Command object. It is not easy to get returned parameter from a stored procedure using DAO ( . However, when dealing with no-return-parameter stored procedure, maybe DAO (using ODBC-Direct or Pass-Through query) is faster than ADO because the former bypass Jet completely.

So, here are my questions.
When accessing/updating remote SQL Server tables, which one is faster, DAO or ADO?

When accessing/updating linked SQL Server tables, which one is faster, DAO or ADO?

When fetching data from a SQL Server stored procedure, which one is faster?
1. ADO
2. DAO using ODBC-Direct
3. DAO retrieving recordset from a pass-through query
Maybe the option 2 and 3 are the same thing.

Seaport
 
I made a mistake on "Accessing/Updating ODBC linked SQL server tables." Jet does not handle the linked table so ADO should perform better than DAO.

Seaport
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top