473,388 Members | 1,256 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

ADO/DAO

JB
I've been away from Access for awhile and am now returning.

When I left, ADO had arrived on the scene, but most people were still
using DAO.

Could someone point me towards some industry statements and opinions as
to which you should be using for new Access development today, and to
some more enlghtened Usenet arguments about the same topic?

Thanks in advance.

Nov 12 '05 #1
10 1521
> Could someone point me towards some industry statements and opinions as
to which you should be using for new Access development today, and to
some more enlghtened Usenet arguments about the same topic?


AFAIK, ADO doesn't play well with some Automation functions. I use a lot of
Automation in my mdb and also had trouble with using bookmarks in a cloned
Recordset (may have been my error), so I went with DAO. But ADO is the
access method of choice otherwise.
Nov 12 '05 #2
DAO is the natural language of the Jet database engine, and the language of
choice if you are using Jet (the default when you use Access as installed).

DAO and Jet are "in maintenance mode", that is only bugs that affect other
products are expected to be fixed (though Microsoft has, in fact, done some
corrections and enhancements beyond what their policy states since they have
been in maintenance mode.

There was a good deal of "hype" about ADO, which some "took to heart", when
it came out. But the "classic ADO" used and still used in Access is also a
_dead-end_. The successor is already released, ADO.NET, which shares only
part of the name, and is built on a different object model.

There has been recent information from knowledgeable Microsoft insiders
that, at least "in general", it is even better to use MDB-Jet-ODBC-MS SQL
Server (could be any ODBC-compliant server DB, though) than to use the
Access Project, ADP, ADODB, MS SQL Server (and, far as I know, this can ONLY
be used with Microsoft SQL Server, not any other server database).

Thus, I would have to differ, strongly, with deko's advice.

Larry Linson
Microsoft Access MVP
"JB" <gy**********@jmjservices.com> wrote in message
news:1O*******************@fe2.columbus.rr.com...
I've been away from Access for awhile and am now returning.

When I left, ADO had arrived on the scene, but most people were still
using DAO.

Could someone point me towards some industry statements and opinions as
to which you should be using for new Access development today, and to
some more enlghtened Usenet arguments about the same topic?

Thanks in advance.

Nov 12 '05 #3
> There was a good deal of "hype" about ADO, which some "took to heart",
when
it came out. But the "classic ADO" used and still used in Access is also a
_dead-end_. The successor is already released, ADO.NET, which shares only
part of the name, and is built on a different object model.


Perhpas what I've been reading is hype. That's okay with me since I've
become pretty comfortable with DAO. I thought ADO was going to replace DAO?
Nov 12 '05 #4
"JB" <gy**********@jmjservices.com> wrote in message
news:1O*******************@fe2.columbus.rr.com...
I've been away from Access for awhile and am now returning.

When I left, ADO had arrived on the scene, but most people were still
using DAO.

Could someone point me towards some industry statements and opinions as
to which you should be using for new Access development today, and to
some more enlghtened Usenet arguments about the same topic?

As a general rule we use DAO with Jet and ADO with SQL Server, the only two
databases we work with). There are some exceptions. Some of the newer
data-aware ActiveX controls, like the Office Web controls ,use ADO. There is
also some ADO functionality that's not available with DAO AFAIK, like using
streams which are handy when working with XML. Also there are some SQL DDL
statements that can only be executed against Jet databases using an ADO
connection, (I think check and default constraints), - but of course you can
always manipulate field DAO objects directly. If you want to work with
linked tables you must use DAO. There may be more.
Best way is to learn both.

Nov 12 '05 #5
"deko" <de**@hotmail.com> wrote in message
news:ax***************@newssvr27.news.prodigy.com. ..
Could someone point me towards some industry statements and opinions as
to which you should be using for new Access development today, and to
some more enlghtened Usenet arguments about the same topic?
AFAIK, ADO doesn't play well with some Automation functions. I use a lot

of Automation in my mdb and also had trouble with using bookmarks in a cloned
Recordset (may have been my error), so I went with DAO. But ADO is the
access method of choice otherwise.


Not so. While it's true that Access 2000 and 2002 had a reference to ADO
chosen by default, Access 2003 is back to having a default reference to DAO
(although it also has an ADO reference by default, and the ADO reference is
higher in order)

ADO is dead: it's been replaced by ADO.Net, which is considerably different.

DAO, while no longer actively supported, is still the better method if
you're strictly dealing with Jet databases (i.e. MDB files). It was
developed specifically for the Jet Engine, so is more efficient.

Michka wrote a good article entitled "What does DAO have that ADO/ADOx/JRO
do not have (and might never have!)" almost 4 years ago, and, as far as I'm
aware, it's still true today. http://www.trigeminal.com/usenet/usenet025.asp

--
Doug Steele, Microsoft Access MVP
http://I.Am/DougSteele
(No private e-mails, please)

Nov 12 '05 #6
"deko" <de**@hotmail.com> wrote in
news:xi*******************@newssvr25.news.prodigy. com:
There was a good deal of "hype" about ADO, which some "took to
heart",

when
it came out. But the "classic ADO" used and still used in Access
is also a _dead-end_. The successor is already released, ADO.NET,
which shares only part of the name, and is built on a different
object model.


Perhpas what I've been reading is hype. That's okay with me since
I've become pretty comfortable with DAO. I thought ADO was going
to replace DAO?


It should have been obvious to anyone who stopped to think about it
that ADO could never replace DAO for Jet data stores.

Think about what ADO actually is: like ODBC, it is a database
abstraction layer that sits between client applications and the
database engines. Its advantages is in providing a common interface
to many different database engines. ADO is a great advance over ODBC
in that it can have much more smarts about the back end db engine,
and because it simply incorporates support for a larger superset of
db engine features.

Now, what is DAO?

It's the interface layer between applications and Jet.

Period.

It is abstracted from Jet at a certainly level, in that it's not Jet
itself, but a layer on top of it. But it is not abstracted at any
higher level as ODBC and ADO are, because it only needs to deal with
one db engine.

So, it should be blazingly obvious that DAO will always be superior
for getting to Jet data, since it's Jet's native data access
interface.

In short, MS's promotion of ADO in Access databases by not having a
DAO reference by default never had any technical merit to it. It was
always first and foremost a marketing move. A2K3 is better in that
they include both references, but they still get it backwards by
putting the ADO reference first (so it gets preference).

Lots of ADO is available through the Access.Application object, such
as the one thing that DAO lacks that ADO provides, the UserRoster.
And for things that aren't natively available, one can easily use
late binding for the few things ADO offers that DAO lacks.

Now, if you're not using a Jet back end or you're not using an MDB
but an ADP, then all bets are off.

But Microsoft definitely steered the unwary Access developer down
the garden path with the ADO promotion that had no technical
justification whatsoever.

But I repeat: that was quite obvious at the time to anyone who gave
the subject a few minutes of thought. The later abandonment of ADO
in favor of ADO.NET was just icing on the cake to prove that on the
subject of ADO and Access, Microsoft's marketing is more important
than technical merit or suitability to task.

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 12 '05 #7
"John Winterbottom" wrote
As a general rule we use DAO with
Jet and ADO with SQL Server, the
only two databases we work with).
There are some exceptions. Some
of the newer data-aware ActiveX
controls, like the Office Web controls,
use ADO. There is also some ADO
functionality that's not available with DAO
AFAIK, like using streams which are
handy when working with XML. Also
there are some SQL DDL statements that
can only be executed against Jet databases
using an ADO connection, (I think check and
default constraints), - but of course you can
always manipulate field DAO objects directly.
If you want to work with linked tables you
must use DAO. There may be more.
Classic ADO is appropriate, certainly, for classic .asp pages. Perhaps it is
just the ticket if you are working with XML from code _in Access_, as well,
but I haven't had occasion to need to do that.

Just about everyone I know who is serious about web-based applications is
now using .NET, for which classic ADO is not appropriate, because the better
(and quite different) ADO.NET has succeeded it there.

If "something else" supplants both DAO and ADO in future versions of Access,
I'd say ADO.NET is a likely candidate. However, I caution that Microsoft has
had many, many "flavor of the current release" access methods over time that
were promoted as "access method of choice for the foreseeable future". My
recollection is that classic ADO was hyped just as much in VB 6 as in Access
2000 and later, but of course classic VB died with VB 6. So, when the time
comes for a successor to DAO and ADO, it could be something else again,
something we haven't even dreamt of yet.

My limited experience working with ADP / ADO against SQL Server is that it
is workable, but often a "pain". Everyone involved with the ADP on which I
am currently doing some work has a separate MDB linked to the same MS SQL
Server tables for quick adhoc queries, etc., against the tables and data.
Best way is to learn both.
I respectfully disagree. My personal approach was, I'll bother learning
another dead-end access method only when I have a client whose work demands
it. I got one, they had swallowed someone's statement that "the only way to
get performance from MS SQL Server with Access is with an ADP", invested in
the conversion, and weren't interested in investing in a re-conversion (they
are expecting that the functionality of the application is going to be
"folded in" to the corporate CRM system within a couple of years -- I am
expecting they are going to need someone applying "band-aids" to the app for
more than a couple of years, based on my observation of typical corporate
CRM implementations).

That would still be my advice to others: don't bother to invest your time
and energy in learning an access method that is already doomed, because its
successor (ADO.NET) is already on the scene, UNLESS you get some paying work
that demands you use it. Then, make a judgement, if appropriate, whether the
pay for the work will be worth the time and effort learning ADO. (But, my
experience so far is that everything except the I/O works so similarly in
ADPs to the way it does in MDBs that the learning curve isn't as steep as
I'd expected. If you have to do much nitty-gritty I/O from code, you are
going to find some differences.)

Larry Linson
Microsoft Access MVP
Best way is to learn both.

Nov 12 '05 #8
"Larry Linson" <bo*****@localhost.not> wrote in message
news:cX******************@nwrddc02.gnilink.net...

I respectfully disagree. My personal approach was, I'll bother learning
another dead-end access method only when I have a client whose work demands it. I got one, they had swallowed someone's statement that "the only way to get performance from MS SQL Server with Access is with an ADP", invested in the conversion, and weren't interested in investing in a re-conversion (they are expecting that the functionality of the application is going to be
"folded in" to the corporate CRM system within a couple of years -- I am
expecting they are going to need someone applying "band-aids" to the app for more than a couple of years, based on my observation of typical corporate
CRM implementations).

That would still be my advice to others: don't bother to invest your time
and energy in learning an access method that is already doomed, because its successor (ADO.NET) is already on the scene, UNLESS you get some paying work that demands you use it. Then, make a judgement, if appropriate, whether the pay for the work will be worth the time and effort learning ADO. (But, my
experience so far is that everything except the I/O works so similarly in
ADPs to the way it does in MDBs that the learning curve isn't as steep as
I'd expected. If you have to do much nitty-gritty I/O from code, you are
going to find some differences.)


We've been waiting for the "next Access access method" for some time now.
It's easy for you to say "don't learn ADO and don't learn DAO" to others if
you already know at least one of them yourself. But for someone who knows
neither you are effectively saying "don't develop any Access applications
until some unknown time in the future, when ADO.NET may or may not be
incorporated into Access. Perhaps they should just go fishing until then.
Actually, that may not be such a bad idea <g>

And we are not talking about difficult subjects to learn. 95% of my DAO or
ADO code is essentially the same thing; opening recordsets, or executing
queries or stored procedures. I doubt it would take longer than a few days
of solid study to learn both, at least to the point of being functionally
literate. .
Nov 12 '05 #9
"John Winterbottom" <as******@hotmail.com> wrote in
news:c7************@ID-185006.news.uni-berlin.de:
It's easy for you to say "don't learn ADO and don't learn DAO" to
others


But that's not what Larry said. What he said amounts to "Learn DAO
because you will always need it, and learn ADO if you are ever
required to."

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc
Nov 12 '05 #10
Thanks, David. You said, succinctly, what I _almost_ said in many more
words.

Larry Linson
Microsoft Access MVO

"David W. Fenton" <dX********@bway.net.invalid> wrote in message
news:Xn**********************************@24.168.1 28.86...
"John Winterbottom" <as******@hotmail.com> wrote in
news:c7************@ID-185006.news.uni-berlin.de:
It's easy for you to say "don't learn ADO and don't learn DAO" to
others


But that's not what Larry said. What he said amounts to "Learn DAO
because you will always need it, and learn ADO if you are ever
required to."

--
David W. Fenton http://www.bway.net/~dfenton
dfenton at bway dot net http://www.bway.net/~dfassoc

Nov 12 '05 #11

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: William C. White | last post by:
Does anyone know of a way to use PHP /w Authorize.net AIM without using cURL? Our website is hosted on a shared drive and the webhost company doesn't installed additional software (such as cURL)...
2
by: Albert Ahtenberg | last post by:
Hello, I don't know if it is only me but I was sure that header("Location:url") redirects the browser instantly to URL, or at least stops the execution of the code. But appearantely it continues...
3
by: James | last post by:
Hi, I have a form with 2 fields. 'A' 'B' The user completes one of the fields and the form is submitted. On the results page I want to run a query, but this will change subject to which...
0
by: Ollivier Robert | last post by:
Hello, I'm trying to link PHP with Oracle 9.2.0/OCI8 with gcc 3.2.3 on a Solaris9 system. The link succeeds but everytime I try to run php, I get a SEGV from inside the libcnltsh.so library. ...
1
by: Richard Galli | last post by:
I want viewers to compare state laws on a single subject. Imagine a three-column table with a drop-down box on the top. A viewer selects a state from the list, and that state's text fills the...
4
by: Albert Ahtenberg | last post by:
Hello, I have two questions. 1. When the user presses the back button and returns to a form he filled the form is reseted. How do I leave there the values he inserted? 2. When the...
1
by: inderjit S Gabrie | last post by:
Hi all Here is the scenerio ...is it possibly to do this... i am getting valid course dates output on to a web which i have designed ....all is okay so far , look at the following web url ...
2
by: Jack | last post by:
Hi All, What is the PHP equivilent of Oracle bind variables in a SQL statement, e.g. select x from y where z=:parameter Which in asp/jsp would be followed by some statements to bind a value...
3
by: Sandwick | last post by:
I am trying to change the size of a drawing so they are all 3x3. the script below is what i was trying to use to cut it in half ... I get errors. I can display the normal picture but not the...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.