Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

JetEngine compact database problem

Status
Not open for further replies.

nanin

Programmer
Aug 29, 2003
13
ES
I've built an application in which I can select a Jet Database (usually MS access) and then compact. The problem is that I have to chage the database version but the JetEngine->CompactDatabase (which I imported from "Import from type library") function in Builder hasn't got enough parameters. How could I solve this?

MSDN:
DBEngine.CompactDatabase olddb, newdb, locale, options, password

Builder parameters: olddb, newdb only
I need "options" parameter.
 
JetEngine is a COM object which has its own API. If you use some Borland wrappers there are other API's. So you should know what you are using, COM object directly or some special Borland 's Wrappers for that object.

Ion Filipski
1c.bmp
 
I solved the problem inserting this connection paramenter into the new database connection string before it had been compacted:

Jet OLEDB:Engine Type=5

so: Provider=Microsoft.Jet.OLEDB.4.0;Data Source=DB.mdb;Jet OLEDB:Engine Type=5


you can change the engine type from 1 to 5:

jet 1.0 ->1
jet 1.1 ->2
.
.
.
jet 4.x ->5 MS Access 2000
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top