Solved

What is the future of DAO in ms access 2010 and later?

Posted on 2012-03-22
8
775 Views
Last Modified: 2012-06-27
Hi:
"If you are developing an MS Access database (back-end) then DAO is probably your best bet as it is optimized for Jet/ACE.  It should also be noted, from what I have read, that Microsoft recommends DAO for Jet data and as such is typically faster than ADO in this scenario.
On the other hand, if you are developing an Access Data Project (.adp) in conjunction with an SQL Server database (back-end), it is normally recommended that you use ADO. "
See url http://www.devhut.net/2010/09/09/ms-access-vba-ado-vs-dao/
I am about to upgrade my ms_access.mdb(s) to ms_access.accdb(s). and I was thinking of changing all of my apps code from DAO to ADO. But when I had read this article I decided to stop and ask the most experts I trust in.
So please help me to take my decision of keep using DAO in my 2010 ms access or convert to ADO?
Notice that all of my 2003 apps are (mdb), and none of them are (adp).
0
Comment
Question by:Mohammad Alsolaiman
8 Comments
 
LVL 75

Accepted Solution

by:
DatabaseMX (Joe Anderson - Access MVP) earned 300 total points
ID: 37754964
DAO. Period. DAO is not going away. Guaranteed!  
Long Live Access, JET, DAO & VBA.

DAO is optimized for Access databases (MDBs and ACCDBs).

mx
0
 
LVL 74

Assisted Solution

by:Jeffrey Coachman
Jeffrey Coachman earned 20 total points
ID: 37755706
Here is a thread MX and some other Experts were involved in, if it helps:
http://www.experts-exchange.com/Software/Office_Productivity/Office_Suites/MS_Office/Word/Q_27595785.html
0
 
LVL 61

Assisted Solution

by:mbizup
mbizup earned 80 total points
ID: 37756562
Agree with the above comments -

Leave your DAO code as-is.

The future of ADPs, however is somewhat uncertain.  

With that in mind, if you find the need to upsize your back-ends to SQL Server, regular Access front-ends (mdb, accdb) play very nicely with SQL Server back-ends.  There is no need to change to or develop ADPs to support SQL Server back-ends.  Your existing mdbs and accdbs will accommodate SQL Server back ends nicely, and your DAO code will work (no need to change to ADO).
0
 
LVL 57

Assisted Solution

by:Jim Dettman (Microsoft MVP/ EE MVE)
Jim Dettman (Microsoft MVP/ EE MVE) earned 75 total points
ID: 37756902
I'd stick with DAO as the others have said.   Next version of SQL Server won't support OLEDB from what I've heard.

You will still be able to use ADO, but it will have to be through a ODBC connection.  While ADO gives you more control over the cursor, when being used with Access, your cursor options are limited anyway, so ADO is not such a big advantage.

 Also, ADO does some weird stuff (schema specific calls) to handle things such as security and what not.

I've pretty much stuck with DAO over the years and never really had a problem.

One big advantage of ADO however is that it is closer to object orientated programming and deals with more data sources.  For example, you can talk to an Excel spreadsheet with ADO, where as with DAO you cannot expect through an ISAM driver built into Access.

All in all though, I'd stick with DAO and just use ADO when needed (you can use both in the same project).

FWIW,
Jim.
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 
LVL 20

Assisted Solution

by:clarkscott
clarkscott earned 25 total points
ID: 37780478
You don't need the "DAO" REFERENCES anymore.
Select the Microsoft Office xx.x Access Database Engine Object.

If you want to use DAO methods, declare your databases and recordsets specifically:
dim db as dao.database
dim rst as dao.recordset

Scott C
0
 
LVL 57

Assisted Solution

by:Jim Dettman (Microsoft MVP/ EE MVE)
Jim Dettman (Microsoft MVP/ EE MVE) earned 75 total points
ID: 37781331
Scott,

<<Select the Microsoft Office xx.x Access Database Engine Object.>>

 Just an FYI; that really is DAO.   The name has been changed, but it is still DAO as it always has been.

Jim.
0
 
LVL 75
ID: 37783156
And always will be.  Long Live Access, JET, DAO & VBA.

mx
0
 

Author Closing Comment

by:Mohammad Alsolaiman
ID: 37817141
thanks to all of you guys
great information & nice to me not to change to ADO
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In Debugging – Part 1, you learned the basics of the debugging process. You learned how to avoid bugs, as well as how to utilize the Immediate window in the debugging process. This article takes things to the next level by showing you how you can us…
Experts-Exchange is a great place to come for help with solutions for your database issues, and many problems are resolved within minutes of being posted.  Others take a little more time and effort and often providing a sample database is very helpf…
In Microsoft Access, learn how to use Dlookup and other domain aggregate functions and one method of specifying a string value within a string. Specify the first argument, which is the expression to be returned: Specify the second argument, which …
In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now