In the files section of the VFP forum are several files that check the integrity of
DBF's. I've never tried them, but have heard several are well written..
>Hi,
>
>Thank very much on the sample code.
>Will be using it for my application.
>
>However, just like to check with you whether
>any reliable way to check for dbf file corruption
>too as my application often had index corruption
>which can be solve by reindexing but
>sometimes, it is actually dbf file corruption in
>the middle of the file causing me to waste time
>in reindexing the file. Any way to do it in
>vfp or codebase ?
>
>
>>Virusim,
>>
>>It is very reliable. But it can be disk intensive for very large tables. The last codebase I worked with
>>this on was 5.1 (I believe)
>>
>>>Hi,
>>>
>>>Thank you very much on the code sample.
>>>Just like to know what version of codebase are you using
>>>as my company only had version 5.1 only.
>>>
>>>How reliable is this method ?
>>>
>>>
>>>
>>>
>>>>Here is a sample of the codebase code to check an index:
>>>>
>>>>
>>>>declare integer d4check in c4dll.dll long
>>>>declare long d4open in c4dll.dll long,string
>>>>declare integer code4accessMode in c4dll.dll long,integer
>>>>
>>>>db = d4open(cb,cFileName) && Codebase .dll wrap
>>>>RetCode = d4check(db)
>>>>=d4unlock(db)
>>>>
>>>>IF RetCode < 0
>>>> MessageBox("index is corrupt.")
>>>>ENDIF
>>>>
>>>>
>>>>>Hi,
>>>>>
>>>>>Thank for your advise. However, you mentioned that CODEBASE had a library
>>>>>to detect corrupted indexes. Can you kindly advise me on which library
>>>>>and the function name plus which version of CODEBASE had this feature
>>>>>as my customer database keep having corrupted indexes.
>>>>>
>>>>>
>>>>>Thank you
>>>>>
>>>>>>CODEBASE makes a library if your interested that can detect corrupt
>>>>>>indexes on open shared files. That is the only way I know of to do it
>>>>>>without writing a low level routine yourself.
>>>>>>
>>>>>>>Hi,
>>>>>>>
>>>>>>>My application run fine, but sometimes, my client server hang, causing
>>>>>>>my application processing data to give error as it can't access the data files giving CDX problem.
>>>>>>>
>>>>>>>Is there any ways before my program process data, that I can detect this problem with CDX or DBF that I can auto do a reindex to solve the
>>>>>>>problem. Any suggestions or advise on how to do it is very much appreciated. Thank you.
Previous
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only