Question Locked

corrupted DBF file

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Situation: corrupted DBF file - no longer open and not writing table file. This file was just great from 1.4 MB it has turned into a 2.6 GB. Apparently corrupt header.
Maybe someone had a similar situation ... please help - very necessary !!!

5 replies

by brijesh(vembu)

Hi,

It is impossible to repair DBF files without using a good DBF repair program. The file needs to be deeply studied, and the data within re-organized making ir readable to a regular DBF reader. The data must also be studied for differences between which sectors of the file are 'newer' than the others. This is usually done by looking at the date and time stamps on the data. If this is inconsistent with the data, then it indicates irregular saving, or errors during the save. This is, as is obvious, most common in corrupt data which is a result of incorrect saving. A good DBF repair software should be able to go through the given file, into the unstructured data, and place the related data packets together where they belong. This restructuring allows a standard DBF file reader to understand the data again and open the file normally.
Once the file is repaired and the data restored, it is recommended to open the file again and save it as a different copy on another medium of storage. This will ensure that you have a non-corrupt copy of the file as backup and don't have to go through the DBF repair software over and over.

Some softwares are provoded for DBF Fix - http://dbfdoctor.com/
corruption of DBF files DBF Repair - http://www.dbf.repairtoolbox.com/

Hope this helps.

by gavinnichols

DBF file can not physically be larger than 2GB. This system limits even FoxPro, and the format DBASE.
The only way - is a manual analysis of information as a plain text file. Most likely, there are "stuck" some "tail", which must be cut off.
But with old stock you can try it.
Can help?
PROC TFD
para n_f
private all like mas
if! '.DBF' $ Upper (n_f)
n_f = trim (n_f) '. dbf'
endif
if! file (n_f)
retu
endif
h = fopen (n_f)
if h = -1
retu .f.
endif
mas = fseek (h, 0,2)
= fseek (h, 8,0)
sl = fread (h, 4)
l_h = asc (subst (sl, 2,2)) * 256 asc (subst (sl, 1,2))
l_r = asc (subst (sl, 4,2)) * 256 asc (subst (sl, 3,2))
= fseek (h, 0,0)
nz_act = (mas-l_h-1) / l_r
if nz_act <= 0
nz_act = 0
endif
hed = fread (h, l_h)
a1 = subs (hed, 7,1)
a2 = subs (hed, 6,1)
a3 = subs (hed, 5,1)
n_z = asc (a1) * 256 * 256 asc (a2) * 256 asc (a3)
if n_z = nz_act
= fclose (h)
retu .t.
endif= fclose (h)
if netf (n_f, 2)
wait wind;
'The destruction of the database file -' upper (n_f) chr (13) ;
'tries fosstanovit file.' chr (13) ;
'Will be lost POSLEDHIH VVEDEHHYH' str (n_z-nz_act, 4) 'RECORDS'
h = fopen (n_f, 2)
clen = cnzap (nz_act)
hed = subst (hed, 1,4) clen subst (hed, 8)
= fseek (h, 0,0)
nb = fwrite (h, hed)
yc = fclose (h)
RETU (nb <> 0 and yc)
Else wait wind;
'The destruction of the database file -' upper (n_f) chr (13) ;
'Requires exclusive mode for data recovery' chr (13) ;
'Start the ARM on a single machine' chr (13) ;
'Will be lost POSLEDHIH VVEDEHHYH' str (n_z-nz_act, 4) RECORDS !!! '
RETU TO MAINPROG
endif
* ----------------------------------------------
funct cnzap
para np
a11 = int (np / (256 * 256))
a12 = int ((np-a11 * 256 * 256) / 256)
a13 = np% 256
retu chr (a13) chr (a12) chr (a11)
--------------------------------------------- *
PROC NETF
para fl, ds
if type ('ds') = 'L'
ds = 0
endif
RETU (fclose (fopen (fl iif ('.' $ Fl, '', '. Dbf'), ds)))
see more information on this forum. there give good advice. here is the link.
http://www.filerepairforum.com/forum/microsoft/microsoft-aa/sql-server/593-foxpro-behavior-when-opening-dbf
yet I can advise to try to solve the problem program DBF Recovery Kit
http://www.all-recovery-inc.com/#!/foxprorecovery

by marypyrons

Get DBF file Recovery is a reliable tool to repair your DBF files created in MS FoxPro or dBase.It also support all versions of DBF database, including dBASE III, dBASE IV, dBASE 5 for dos, dBASE 5 for Windows, FoxBase, FoxPro, Visual FoxPro, etc. This software efficiently recover all the email from corrupted dbf file and save them at your desire location.

Download now: http://www.recoverydeletedfiles.com/dbf-database-recovery-tool.html

This discussion is closed to new replies.