Hi,
How can I determine, if CDX is actual for DBF file (VFP type) ?
I want determine date and time, but I see, that time of cdx is different that dbf (about 2 seconds in my example).
This look, that first save CDX file and then DBF.
In dbf header is only last update - only date, cdx header do not know what is in it.
I can determine only date, and time calculate to permision difference several seconds, but his is not very clear solution.
A reason is , because program can open DBF in "classic old mode " DBF with CDX , or with ODBC driver. When opened with ODBC driver, CDX files is not updated. When again open with CDX, need reindex.
this issue is temporary because the ODBC version is in testing, and then only this one is allowed, but also later can some user run old version of program and I need to notify them
* I try this, max difference set to 30 seconds...
subord:=cestaolp+ozndbf+".DBF"
suborc:=cestaolp+ozndbf+".CDX"
if konfex(subord)=.T. .and. konfex(suborc)=.T.
if filedate(subord)=filedate(suborc) .and. ;
(timetosec(filetime(subord))-timetosec(filetime(suborc)))<30
return 1 // ok
else
return 2 // inconsitency
endif
else
return(0) // cannot open
endif
DBF/CDX consistency
Re: DBF/CDX consistency
Xbase++ DATA Component have CacheVictorio wrote:This look, that first save CDX file and then DBF.
while ORDER Component do not to have Property "LIFE_TIME" so Index is 1stFOXDBE (DATA-Komponente)
FOXDBE_LIFETIME a 50 N Lifetime of records in local cache
DBFDBE (DATA-Komponente)
DBFDBE_LIFETIME a 50 N Verweildauer von Records im lokalen Cache
greetings by OHR
Jimmy
Jimmy
Re: DBF/CDX consistency
Do you do a dbCommit() after your dbAppend() ?
The eXpress train is coming - and it has more cars.
Re: DBF/CDX consistency
Roger, no, I have only append, on same places I have also commit but in this no, I will try it
Jimmy I searched what parameter in dbesys can miss or be wrong, I will look for as you advice
Thank's
Jimmy I searched what parameter in dbesys can miss or be wrong, I will look for as you advice
Thank's