Solved

Connect to an Access MDB without using BDE?

Posted on 2009-04-02
3
556 Views
Last Modified: 2013-11-23
Is it possible to connect to a Microsoft Access MDB file without using the Borland Database Engine?  If 'yes,' then how?
0
Comment
Question by:Monroe406
[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
  • 2
3 Comments
 
LVL 26

Expert Comment

by:Russell Libby
ID: 24056192
You have two other choices:

- Direct ODBC
- ADO

If the version of Delphi that you are using has the AdoExpress components then you are all set. Even if it does not, you can still import the type library information from msado15.dll which will give you the automation interface wrappers into ADO (and thus allow you to get the jet mdb). The other alterntive, and probably at a level you don't want to deal with, is by using direct ODBC SQLxxxx calls.

Your best bet is to figure out if you have the component wrappers for ADO in your version of Delphi. If you do, then check the help files for info regarding props/methods. If you don't, then import the ADO type library info and check the MSDN online for examples using ADO. Its fairly simple to use, and there are a number of resources on line for help.

Regards,
Russell
0
 

Author Comment

by:Monroe406
ID: 24056286
>> If the version of Delphi that you are using has the AdoExpress components then you are all set

I am looking at my Delphi 7 component bar, and I only see "ADO", not "AdoExpress".

When I look at my Delphi 2005 component list, I see a dbGo group with some ADO components.

I also have heard that using DAO is more efficient than ADO.  True?
0
 
LVL 26

Accepted Solution

by:
Russell Libby earned 125 total points
ID: 24056489

If you have an ADO component group, then you have"AdoExpress" installed which is what provides the components. (AdoExpress - Borland's terminology for the component wrappers they wrote which encapsulate the ADO COM interfaces by way of components).

As to DAO, that might have been true 10 years ago, but I would be hard put to believe it nowadays without evidence. DAO is antiquated, and moreover I'm not sure if its still even supported. Jet has a native OLEDB driver, which can be accessed via ADO (ADO is simplified wrapper over OLEDB). If you use the TAdoConnection and related components, you will find that you can access your mdb in the same fashion as you might have with the BDE, sans the BDE.

Russell
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Multiple image collision 13 111
Dev express lookupcombo 3 64
update joined tables 2 74
Typecasting TBytes to Integer in Delphi XE8 2 69
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Introduction Raise your hands if you were as upset with FireMonkey as I was when I discovered that there was no TListview.  I use TListView in almost all of my applications I've written, and I was not going to compromise by resorting to TStringGrid…
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

752 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