🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.cppbuilder.database.ado
Article #4052

Re: Inserting data into MS Access

#4052
From: Jerry Irons
Date: Wed, 24 Apr 2002 19:45
26 lines
1793 bytes
Drop ADODataset onto form.  Build property connection string using MS
Jet ole provider.  Select your database name, and test the connection.
You may want to change your access permissions to read/write.  Next,
edit your property command set to include whatever tables and fields
from the mdb database.

Rest works like ttable or tquery.  Ie 

ADODataset->Open();
ADODataset->Insert();
ADODataSet->FieldByName("LASTNAME")->AsString = "Smith" ;
ADODataSet->Post();
ADODataSet->Close();

This of course assumes that you have already created your mdb
database, and tables with field types using ms access.

Also, for speed, use the UseServer cursor location as property of
adodataset.

I'm not sure why, but it has been recommended by some to use
adodataset and not ttable or query.  I think for speed reasons.
ADOTable works off of an sql string anyway.

-jerry
Technical Details
Message-ID: <792ecukoeibadvbctqa8loinohhrsj471g@4ax.com>
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!195.40.4.120.MISMATCH!easynet-quince!easynet.net!proxad.net!newsfeed.media.kyoto-u.ac.jp!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!dnews
References: <3cc6baaf_2@dnews>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10698b,6b5471357352571a
X-Google-Attributes: gid10698b,public
X-Google-ArrivalTime: 2002-04-24 12:46:33 PST
From: Jerry Irons <JIrons@compuserve.com>
Newsgroups: borland.public.cppbuilder.database.ado
Subject: Re: Inserting data into MS Access
Date: Wed, 24 Apr 2002 15:45:01 -0400
Message-ID: <792ecukoeibadvbctqa8loinohhrsj471g@4ax.com>
References: <3cc6baaf_2@dnews>
X-Newsreader: Forte Agent 1.8/32.548
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
NNTP-Posting-Host: 24.54.10.7
X-Trace: dnews 1019677550 24.54.10.7 (24 Apr 2002 12:45:50 -0700)
Lines: 27
Path: arc1-ca.pugleaf.net!archiver1.google.com!news1.google.com!sn-xit-02!sn-xit-01!supernews.com!195.40.4.120.MISMATCH!easynet-quince!easynet.net!proxad.net!newsfeed.media.kyoto-u.ac.jp!nntp-relay.ihug.net!newsfeeds.ihug.co.nz!ihug.co.nz!dnews