压缩数据库
var
dao: OLEVariant;
begin
dao := CreateOleObject('DAO.DBEngine.36');
dao.CompactDatabase('d:/yourDatabaseName.mdb',
'd:/yourNewCompactedDatabaseName.mdb');
end;
修复数据库
var
dao: OLEVariant;
begin
dao := CreateOleObject('DAO.DBEngine.36');
dao.RepairDatabase('d:/yourDatabaseName.mdb');
end;