Re: My access database file just keeps getting bigger
- From: Andy Stephenson <info2004@xxxxxxxxxxxxx>
- Date: Fri, 25 May 2007 16:41:31 +0100
Vassiliev,
Thanks for that. I'll give it a go.
Regards,
Andy
Vassiliev V. V. wrote:
You can compact MS Access database - import "Microsoft Jet and Replication Objects 2.X Library"..
var
engine: IJetEngine;
src, dst: WideString;
begin
src := 'Provider=Microsoft.Jet.OLEDB.4.0;Data Source=' + 'C:\SrcDB.mdb';
dst := 'Provider=Microsoft.Jet.OLEDB.4.0;Data Source=' + C:\compacted.mdb';
engine := CoJetEngine.Create();
engine.CompactDatabase(src, dst);
end;
This will also repair database. You always compact into another database.
All users should be disconnected. After this you could copy compacted.mdb in
place of srcdb.mdb.
//------------------------------------------
Regards,
Vassiliev V. V.
http://www.managed-vcl.com - using .Net objects in Delphi for Win32 +
ADO.Net
http://www.oledbdirect.com - The fastest way to access MS SQL Server,
MS Jet (Access) and Interbase (through OLEDB)
"Andy Stephenson" <info2004@xxxxxxxxxxxxx> ???????/???????? ? ???????? ?????????: news:464dca75$1@xxxxxxxxxxxxxxxxxxxxxxxxxHi,
I'm using an access file to form a queue between my app and an sql database. If I can't connect, I send the data to the access database. Later, when I can connect, I send the data to the sql server, and delete it from the access database.
However, the access database file just keeps on getting bigger. If I use access to have a look at it, it contains no data. I am guessing that when I delete the data, it is being retained.
Is this really the case, and if so, how do I really get rid of it?
Thanks,
Andy
- References:
- My access database file just keeps getting bigger
- From: Andy Stephenson
- Re: My access database file just keeps getting bigger
- From: Vassiliev V. V.
- My access database file just keeps getting bigger
- Prev by Date: Re: OTHER BIG BUG : deleting detail master delete
- Next by Date: TADOQuery SaveToFile XML with PostgreSQL
- Previous by thread: Re: My access database file just keeps getting bigger
- Next by thread: 'Registering' ADO Dlls
- Index(es):
Relevant Pages
|