Board index » delphi » BDE BLOWS UP! When Reindex dBase IV tables

BDE BLOWS UP! When Reindex dBase IV tables

I run an overnight ReIndex program to recreate all .MDX files anew. In this
program
I am using the BDE functions DbiRegenIndex, DbiRegenIndexes and
DbiPackTables.
When I a try to reindex a table that has a damaged .MDX file the BDE Blows
up!
completely. Freezing the program and even completely killing the Windows
environment.

If I use dBase IV, or  Visual dBase 7 to reindex the same table they both
give me an
error message telling me what the problem is and asking me if I want to
disconnect the
index or convert it to dBase type index. I suppose the BDE somewhere lacks
the correct exception code to provide a more discreet exit in case of a
problem an instead it just
panics and freezes up. I need to run this Reindex function continuously and
I would like to run it using BDE functions if possible.

Has anyone else experienced this problem and does anybody know of a solution
for it.

Thank you very much

Gilbert Loza

 

Re:BDE BLOWS UP! When Reindex dBase IV tables


On Fri, 7 Apr 2000 16:38:37 -0700, in the borland.public.bde group,
Gilbert Loza said...
Quote
> I run an overnight ReIndex program to recreate all .MDX files anew. In this
> program
> I am using the BDE functions DbiRegenIndex, DbiRegenIndexes and
> DbiPackTables.
> When I a try to reindex a table that has a damaged .MDX file the BDE Blows
> up!
> completely. Freezing the program and even completely killing the Windows
> environment.

> If I use dBase IV, or  Visual dBase 7 to reindex the same table they both
> give me an
> error message telling me what the problem is and asking me if I want to
> disconnect the
> index or convert it to dBase type index. I suppose the BDE somewhere lacks
> the correct exception code to provide a more discreet exit in case of a
> problem an instead it just
> panics and freezes up. I need to run this Reindex function continuously and
> I would like to run it using BDE functions if possible.

> Has anyone else experienced this problem and does anybody know of a solution
> for it.

Depending upon the version, reindexing will not fix a corrupted .mdx tag,
(e.g IV will not, 7 will).  Go to
news.dbase2000.dbase.binaries newsgroup and get this article...

Date: Wed, 17 Nov 1999 10:56:33 +0200
Subject: recreate indexes
From: "Robert Bravery" <m...@u.com>
Newsgroups: dbase.binaries

It is a utility written by Romain Streiff that analyzes a table, records
the pertinent index key information and writes a program that can be used
to recreate the .mdx after it has been detached from the .dbf by changing
the appropriate byte in the .dbf header.

You could dissect the program to accomplish the same thing in Delphi with
direct calls to the BDE.

Gerald

Other Threads