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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DAO vs. ADO

Status
Not open for further replies.

Chucklez

Programmer
Jul 25, 2002
104
US
Call this a stupid question if you will, but what is the difference between ADO and DAO. Any advantages/disadvantages to each? At present I use DAO, but have been told that ADO is what I should use while programming.

Is there possibly a website that will explain the differences?

Another question, this is a little off topic, Is there a detailed description of the references that are available in Access2000? I would like to know what each reference is used for so that way I may be able to better use them.

Thanks for the help guys,
Chucklez
 
It not a stupid Q but a Q that we all ask ourselfs from time to time.

But I have come to this conslution:

If I am developing MDB front/backend I will use DAO however if I am developing an ADP front and SQL backend I will and indeed must use ADO as DAO is useless in the enviroment.

Herman
 
The main difference that I have found (though am just learning about ADO myself) is that DAO is a connected access tool... it needs to stay connected to the database while it works... (uses more computer resources to maintain the connection, but in a small pc app doesn't make much of a difference)

ADO is a dis-connected access tool... It connects only for very short times any time it needs to get/put data into the database, then disconnects... it doesn't stay connected, so it requires less over head... though making and breaking down the connections creates over head.

My main thought, if I have a constant connection available that wont slow down the computers much, I stick with DAO(I'm much better with DAO), but like now, I'm working on a web database... I must use ADO because I'm connecting to a SQL backend...

Hope my confused ramblings have helped you...

--James
junior1544@jmjpc.net
Life is change. To deny change is to deny life.
 
Indeed, both replies have helped.

The reason I have asked this question is that I am developing a database that will be used over a smaller network (10 users or so). I am going to create a .cdb that the .mde's will conect to. I figure DAO should be fine here, but the next project I am working on will use a database frontend to connect to dbase IV files over a very large network (100 + users).

I didnt know if I should use ADO on the small project as practice for the very large project.

Once again, thanks for the help
Chucklez
 
The biggest difference between DAO and ADO is that ADO is an ActiveX object and has nothing to do with Access. It can be used with Access, but, it can be used with any language that supports ActiveX objects. Microsoft created it as kind of a "universal" data access.

Whether one should use it, depends on your point of view.

I work in muliple languages and like ADO because my data access methods are useful in every one. That way, I don't have to code in DAO and ADO. I use ADO in all cases.

If you're working in Access97 or earlier versions, you don't have ADO available.

Microsoft.com has some nice writeups on ADO and ADO versus DAO. Key in ADO and search away.

Tom.

It may be just an opinion... but it's MY opinion.
 
The biggest difference between ADO and DAO is that ADO is threadable and DAO is not, which means that ADO is more scalable than DAO. You can use DAO to access a SQL backend database (I've done it a number of times), and I believe that it does work in Access 97 if you set the proper reference. ADO is simple to learn. I would recommend that you use for your small project to prepare for your large project. There is much written about it with lots of examples and the transistion is virtually painless.
 
ADO can connect with non-relational data files?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top