FOXCDX and integer
-
- Posts: 42
- Joined: Mon Dec 23, 2013 2:10 pm
- Contact:
Re: FOXCDX and integer
Hi,
Your index file is faulty (poorly tagged it), you must completely rebuild (erase and indexing new) is a defect in dtabaseEngine CDXDBF (reindexing or creating file without deletion does not correct this problem) so you have crush before reconstituting it.
After reconstitution it'll work the way you want.
Messaoud Mohamed Lazhar
Your index file is faulty (poorly tagged it), you must completely rebuild (erase and indexing new) is a defect in dtabaseEngine CDXDBF (reindexing or creating file without deletion does not correct this problem) so you have crush before reconstituting it.
After reconstitution it'll work the way you want.
Messaoud Mohamed Lazhar
Re: FOXCDX and integer
Hi Pedro,
Thanks for your test, but this isn't the problem. When you create the index with Xbase++, it will work.
However, I have to read the existing index from another application which is created with Visual Foxpro. In the DBF the fieldtype is an INTEGER with a lenght of 4. In Xbase this is converted to a Numeric and a search isn't working. I can create a new index, but this isn't updated when the other application adds something to the database. I want to check that database every 5 seconds to update my tables. I can't create a new indexfile every 5 seconds.
Thanks for your test, but this isn't the problem. When you create the index with Xbase++, it will work.
However, I have to read the existing index from another application which is created with Visual Foxpro. In the DBF the fieldtype is an INTEGER with a lenght of 4. In Xbase this is converted to a Numeric and a search isn't working. I can create a new index, but this isn't updated when the other application adds something to the database. I want to check that database every 5 seconds to update my tables. I can't create a new indexfile every 5 seconds.
Re: FOXCDX and integer
Hi Messouad,
Thanks for your answer. I will ask if they have an option to recreate the indexfile from nil in that application.
Thanks for your answer. I will ask if they have an option to recreate the indexfile from nil in that application.
Re: FOXCDX and integer
Can you send the database to me?
I would like to experiment with it.
I would like to experiment with it.
The eXpress train is coming - and it has more cars.
Re: FOXCDX and integer
Hi Roger,
See the second post in this thread. I added the code I used for testing in xdbu and the DBF and CDX.
See the second post in this thread. I added the code I used for testing in xdbu and the DBF and CDX.
Re: FOXCDX and integer
Hi Messouad,
I asked to do a reindexing via the application. The result remains the same. I don't know if that application is creating a new indexfile or just executes a reindex.
I asked to do a reindexing via the application. The result remains the same. I don't know if that application is creating a new indexfile or just executes a reindex.
Re: FOXCDX and integer
Chris -
I think I may have found something that works.
dbSeek( <number>, .t. ) always puts me on the correct record.
dbSeek( <number>, .f. ) always puts me at EOF.
BTW - I think there is something wrong with the index. I also tried opening the file with ADSDBE. It is supposed to be very FoxPro friendly, yet it errors on a dbSkip() when using the ARTCODE index.
Roger
I think I may have found something that works.
dbSeek( <number>, .t. ) always puts me on the correct record.
dbSeek( <number>, .f. ) always puts me at EOF.
BTW - I think there is something wrong with the index. I also tried opening the file with ADSDBE. It is supposed to be very FoxPro friendly, yet it errors on a dbSkip() when using the ARTCODE index.
Roger
The eXpress train is coming - and it has more cars.
-
- Posts: 42
- Joined: Mon Dec 23, 2013 2:10 pm
- Contact:
Re: FOXCDX and integer
Hi,
if you only make re-indexing the file, the problem persists. You must recreate it again (erase the file and indexing)
_________________
Best regards,
Messaoud Mohamed Lazhar
if you only make re-indexing the file, the problem persists. You must recreate it again (erase the file and indexing)
_________________
Best regards,
Messaoud Mohamed Lazhar
Re: FOXCDX and integer
Hi,
Since I can't trust the index created by the other application, I create one myself. If I get an EOF() after a seek, it means that there is new data added. At that moment I recreate the index.
Since I can't trust the index created by the other application, I create one myself. If I get an EOF() after a seek, it means that there is new data added. At that moment I recreate the index.
Re: FOXCDX and integer
Chris -
Did you try my recommendation? - dbSeek( <n>, .t. )
Did you try my recommendation? - dbSeek( <n>, .t. )
The eXpress train is coming - and it has more cars.