Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

ADO, DAO, DataControl ??

Posted on 2000-05-04
6
Medium Priority
?
384 Views
Last Modified: 2013-12-25
I'd like to know in simple terms what the difference is between ADO, DAO and DataControl is so I can get an idea which I should be using.  In addition to the explanation, some links would be helpful.

The application I'm attempting to code right now is pretty simple, but I'd like to build more complex ones in the future if I can ever get a handle on this data access thing.

I'm using VB5, and Access 97 (would prefer to use Access 2000 if I could get that to work with VB5 : )  

Thanks
0
Comment
Question by:Eyekissed
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 2779117
DAO = old technology mostly for accessing Access database.

ADO = Latest data access technology that can use much any data source. Focus on that one since DAO will die.

DataControl: A control that use DAO to facilitate data access. Note that an equivalent control exists for ADO.

One of the best link concerning this is http://www.microsoft.com/data/
0
 
LVL 6

Expert Comment

by:Marine
ID: 2780318
If you going to use Access you will get better performance with DAO because Dao was optimized for Jet.
0
 
LVL 1

Expert Comment

by:billyh
ID: 2781068
DAO: this technique might be old, but is very good for developing LAN-based applications only. That means if you application is to be used in a WAN enviroment it is going to fail badly. Anyway Bill Gates has decided to drop DAO and move on with OLE-DB, which is implemeted through ADO.

ADO is very powerful and connects to different types of Databases, including Oracle. ADO works for both LANs and WANs pretty well. That to me is the only difference. Other than that they are both used to connect to databases.

As for datacontrols, there are two types, there is the DAO data control called DATA in VB, and the ADO data control called ADDODC. This are meant to reduce the level of coding.
0
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

 
LVL 2

Expert Comment

by:Sage020999
ID: 2781511
I currently use both technologies in my programming.  Both have there pluses and minues.  ADO is growing to be a powerful tool, but is still quite lacking when it comes to Access databases, including the new 2000.  Data controls are nice tools but are limited.  There are only a few areas where I would concider using these.  They work extremly well when bound to other controls like spread sheets.
0
 

Accepted Solution

by:
jwilson earned 150 total points
ID: 2782074
If you're just starting out, ADO should be pretty straight forward, but if you need to automatically recover from LAN/WAN connection failures, or the database has been moved, this redirection cannot be accomplished using ADO (as far as I know anyway).

ADO also has significant resource overhead compared to DAO as it is geared towards multiple heterogenious databases...

If you only have 1 database then DAO is by far simpler to use for professional redirection (i.e. zero down time).

I tried to implement a 7x24 system (time recording system for payroll) using ADO, but it failed miserably in this area - DAO on the other hand worked very well for this.

A minus to DAO is it's lack of report protoyping.

Similarly a minus to ADO is it's limited support for a true object model (supposed to be corrected in VB 7's ADO), i.e. enforcing bound controls. To prove this point try to write a function in one project with ADO that you can take with you to another...

To those who disagree,
1. Try to write a function to recover
   from a loss of connection, etc. for
   ADO (my last crack was over 30 lines
   of code and ultimately fails).

2. Then try it with DAO (this one's only
   8 lines of code - 3 years of 7x24).

This last comment is towards emoreau:
Microsoft has announced that DAO will no longer be improved, i.e. no major problems exist, so please use our latest, buggy, marketing scheme - I don't think this should be interpreted as "DAO will DIE"...
0
 
LVL 1

Expert Comment

by:billyh
ID: 2796216
I depends on how much you have given yourself to ADO.

From a hardcore DAO programmer like you and me(jwilson), ADO is completly unfair. Have you ever tried updating a recordset that you declared locally in your code that access an Access DB through SQL.

None-the-less just like in DAO, its just a matter of time until we are comfortable with ADO. I used to have the same problem with lost connections, but I know use re-setting the CONNECTION STRING of the ADO connection, to get back my connection. Yes ADO is very sensitive, but as a programmer, you learn how to work with the limitations.

So don't scare "Eyekissed" ADO is very fun and is more effiecient that DAO in some instances. To "jwilson" try connecting to a SQL server using DAO.
0

Featured Post

Tech or Treat! - Giveaway

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

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

Article by: Martin
Here are a few simple, working, games that you can use as-is or as the basis for your own games. Tic-Tac-Toe This is one of the simplest of all games.   The game allows for a choice of who goes first and keeps track of the number of wins for…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

604 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