New ODBC Data Access Objects - Beta Testers required

New ODBC Data Access Objects - Beta Testers required

Post by Martín Córdov » Sat, 08 Mar 1997 04:00:00



Dear Fellows:

I have developed a component that encapsulates the ODBC API within a very
thin layer, very business focused, without the overhead that is not
ussually required by business apps. The component does use only the most
fast and light functionality of the ODBC API. Has been tested with SQL
Server, Sybase Anywhere and Access Driver (v3.0). Supports BLOBS,
ForwardOnly/ReadOnly cursors (the fastest) using block fetches
(SQLExtendedFetch), transactions and direct query execution. Features
simplified ODBC error management, fully integrated with the Err object.

ODBC DAO is a confirmation that ODBC API direct access is much better than
RDO and DAO. When used as source code, it can be called from 16 and 32 bit
apps. Your I/O code will be fully portable!

ODBC DAO has automatic memory management, you don't have to worry about
closing recordsets or database connections. The object model is strongly
based on DAO, however, it has been simplified (a lot). In fact, you can
control the most important functionality only with six or seven
methods/properties.

At present, ODBC DAO has been used to develop 3 large-scale client/server
apps for the oil industry and public sector (in Venezuela). The concept is
based on several years of experience developing business apps with
different database API's, including DAO, Raima, CodeBasic, ODBC, RDO,
DATABasic and others.

Benchmarks (under the same hardware-software conditions/time expressed in
ms.):

                OPEN DB QUERY & READ ROWSET DLL SIZE        ODBC TRACE SIZE

MS RDO  5880            359                             257K            5,40K

ODBC DAO        3780            276                             34,5K           1,15K

ODBC DAO allows you to mix high level code with ODBC API direct calls. You
can use it as source code (class modules) or as a DLL (InProcess OLE
server). Code sample:

Dim Engine as New CEngine
Dim Db as CDatabase

Sub Form_Load
        Set Db = Engine.OpenDatabase("MyDsn","MyUserID","MyPwd")
End Sub

Sub LoadItems

        Dim Rs as CRecordset

        Set Rs = Db.OpenRecordset("select id, lastname from customer")
        While Not Rs.EOF
                List1.AddItem Rs.Field("lastname")
                Rs.MoveNext
        Wend

        '---you don't have to close the recordset

End Sub

Sub KillCustomers()

        Db.BeginTrans
        Db.Execute "delete from customers"
        Db.Commit

End Sub

The component exports 4 classes:

CEngine, CDatabase, CRecordset and CField

If you want to receive a free copy of the DLL (documentation included) as a

component is royalty free, you can use it as you want, even for commercial
use. I only ask you to send feedback as soon as possible to the same
address. There is no expiration date; beta-testers will receive free
upgrades for an unlimited time.

Also available is the .DOC of the programmer's guide (in spanish, but the
tech/jargon makes it easy to understand).

Please contact me if you have any questions or want to receive more
information about ODBC DAO.

Thanks for your time!


Information systems consultant