Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Best DBF file repair utility?

62 views
Skip to first unread message

Kevin J. Rees

unread,
Jan 27, 1997, 3:00:00 AM1/27/97
to

What is the best DBF file repair utility (and how much and where can I
get it)?

I have run across several cases where a system lost power or crashed in
the middle of a FoxPro session after which FoxPro reported the file
corrupt. Yet upon scanning the file with a file editor, it is mostly
intact. Are there any repair capabilities built into FoxPro of which I
may be unaware?

-- Kevin

Bob Ruple

unread,
Jan 27, 1997, 3:00:00 AM1/27/97
to

Kevin J. Rees wrote:

> What is the best DBF file repair utility (and how much and where can I
> get it)?

A favorite of the Fox gurus is dSalvage. For more info visit this site:

http://www.accutek.com/comtech

This web page contains product information as well as discussions about some
of the more common file damage problems.

> I have run across several cases where a system lost power or crashed in
> the middle of a FoxPro session after which FoxPro reported the file
> corrupt. Yet upon scanning the file with a file editor, it is mostly
> intact. Are there any repair capabilities built into FoxPro of which I
> may be unaware?

Here's more info on the "Not a database file" error message:

I have experienced the "Not a Database File" error many times. This problem
is really not that serious if you know how to handle it. It is seldom seen
in a single user environment and is much more common in a peer-to-peer
non-dedicated server situation than on a Novell network with a dedicated
server.

On a Novell network with a dedicated server this problem will *frequently*
occur if the server goes down, in power outage, for example. For this reason
an uninterruptable power supply (UPS) is recommended for the server if power
interruptions are a problem in your area.

Usually, though not always:

1) The DBF file actual, physical record count does not match the record
count in the DBF file header.
2) The DBF header record count contains one more record than is actually
(physically) present.
3) If you decrement the record count in the DBF header by one the DBF
file pops right back.

WARNING: THE FOLLOWING PROCEDURE CAN DESTROY YOUR .DBF FILE.
ALWAYS MAKE A BACKUP!

Bring up the DBF file in your favorite hex editor (Norton, PCTools, etc.).
Bytes 4-7 contain the record count. Since the hex editor starts counting at
byte 0, it will be the 5th byte in from the left. Decrement it by one, e.g.
if its 05 change it to 04, 0B change it to 0A, etc. Write it out to disk. Go
into FoxPro. Try to USE it. If you still get "Not a Database File," repeat
the procedure, decrementing byte 4 by one again.

The count is stored in the header backwards, or reverse order bytewise, so if
you have to decrement byte 4 past 00, then byte 5 must be changed also. For
example:

Bytes 4-7 # records in DBF
----------- ----------------
FF 00 00 00 255
00 01 00 00 256
FF FF 00 00 65535
00 00 01 00 65536

So in row two of the above table (00 01 00 00 = 256 records) if you wanted to
decrement the record count in the DBF by one (to 255 records) you would have
to change both byte number 4 (to FF) and byte number 5 (to 00). (FF 00 00 00
= 255). This same principle pertains across all four bytes.

This procedure looks hard, but its really simple. It doesn't work all the
time, but a lot of the time it does.

Also, there is an article in the November 1993 FoxPro Advisor magazine
entitled "So It's Not A Database File," on page 20 that will tell you
everything you need to know about how to handle this situation, and then
some. It was written by Fox gurus Jim Booth and Paul Heiser. Paul is the
developer of the aforementioned dSalvage file recovery utility.

Hope this helps...


--
Bob Ruple
http://www.ix.netcom.com/~bruple

ErxMeister

unread,
Feb 1, 1997, 3:00:00 AM2/1/97
to

something I came across DBRX.EXE, has worked every time for me

bibo...@gmail.com

unread,
Jul 4, 2012, 2:14:32 AM7/4/12
to kr...@kelisys.com
Kernel recovery for DBF is very proficient tool that effectively repairs DBF files for both severe and minor corruption. The utility is provided with the advanced algorithms that ensures efficient data recovery from the corrupt database files. The software supports different Dbase versions such as Dbase I, II, III, IV and V. Moreover, the utility also works on several versions of Foxbase, Fox pro and Visual Fox Pro. An user is required to buy the license key of the recovery program, in order to save the retrieved files on his/her system
You can get this utility from http://www.repairdbf.net/

On Monday, January 27, 1997 1:30:00 PM UTC+5:30, Kevin J. Rees wrote:
> What is the best DBF file repair utility (and how much and where can I
> get it)?
>
> I have run across several cases where a system lost power or crashed in
> the middle of a FoxPro session after which FoxPro reported the file
> corrupt. Yet upon scanning the file with a file editor, it is mostly
> intact. Are there any repair capabilities built into FoxPro of which I
> may be unaware?
>
> -- Kevin

jerome19...@gmail.com

unread,
Jun 12, 2013, 2:37:42 PM6/12/13
to
Make use of vfp9 dbf repair utility

Material http://www.dbf.repairtoolboxx.com will give you a lot of various instruments for restoring .dbf files
0 new messages