1. Jonathan Ashwell
  2. Valentina Database ADK
  3. Montag, Dezember 04 2017, 04:33 PM
  4.  Abonnieren via E-Mail
I have a db with a table (thereferences) that has bad index (diagnose -> problems). When I reindex in VStudio the problem is fixed. But when I try to do this in my app diagnose still reports problems. I'm using this code -- what am I doing incorrectly?

call myDatabase.SqlExecute("Reindex table thereferences";)
Kommentar
There are no comments made yet.
François Van Lerberghe Akzeptierte Antwort
This happens to me too. Valentina 5.8.8 + Xojo (Realbasic).
I must
- close the db
- trash the index file
- open again the db
in order to correct the problem.

Best regards
Kommentar
There are no comments made yet.
Jonathan Ashwell Akzeptierte Antwort
I should have said I'm using Valentina 7.5.2 and Xojo, and the index is in the bundle. I assumed that because VStudio worked the problem is with my code, but since it's happening to you, too, maybe it's a longstanding bug V4RB?

Ivan?
Kommentar
There are no comments made yet.
François Van Lerberghe Akzeptierte Antwort
In fact, sometimes (for some index corruption), this is working well, but not all the time as in VStudio.
Kommentar
There are no comments made yet.
Ivan Smahin Akzeptierte Antwort
Could you send me the diagnose log (high verbose level) and db for testing?
Probably this is not related to the particular index only - what about reindex whole database?
Trashing index file is an option as well.
Could you describe what happens more specific? Does error reappear after your app activity only? What do you do there specifically?
Kommentar
There are no comments made yet.
Jonathan Ashwell Akzeptierte Antwort
I've sent it to you as an email attachment.

I've tried "Reindex database" too, with no success.

I can't trash the index file because it's in the db bundle.

This is what happens:

1. Diagnose -> problems with index of one table.
2. I reindex that table.
3. Diagnose again -> same problems.

As I said, if I reindex that table in VStudio a new diagnose -> no problems. But when I do this programmatically (V4RB, version 7.5.2) it fails.
Kommentar
There are no comments made yet.
Ivan Smahin Akzeptierte Antwort
As far as I get it - you do
- SQL statement "reindex database" in your app;
- close db (or your app);
- open db with vStudio and do diagnose. And here you see index errors anyway.

If you do the same steps, but with vStudio - no errors.

Correct?

Probably, your app was crashed/aborted for some reason, and result of "reindex database" was not flushed to the disk. In other words - db was not closed correctly (BTW, you should see a warning from vStudio). In such case, db.Open causes restoring db to the last known state (following db-journal).
Kommentar
There are no comments made yet.
Jonathan Ashwell Akzeptierte Antwort
No, no, no! There was NO crash! It's not just this library. NO Library I try reindex on works!!!!! This is just one example.

Did you try reindexing the library I sent you programatically?

Please don't brush this off -- corrupt indexes are the most common problem I see with Valentina and I need to be able to fix them from within my app.

This is a Valentina bug as far as I'm concerned. Please investigate and fix it.
Kommentar
There are no comments made yet.
Ruslan Zasukhin Akzeptierte Antwort
Hi Jon,

Bug fixed in the new alg (v7.5.1) to reindex by words.

New hotfix build 7.5.6 uploaded into
http://valentina-db.com/download/prev_releases/

please try and confirm that issue is solved.
Kommentar
There are no comments made yet.
Jonathan Ashwell Akzeptierte Antwort
Yes, it works! Thank you and Ivan for fixing this so rapidly.

Jon
Kommentar
There are no comments made yet.
Ruslan Zasukhin Akzeptierte Antwort
Thank you for confirmation. I will close this issue here,
and will push 7.5.6 release into public place.
Kommentar
There are no comments made yet.
  • Seite :
  • 1


There are no replies made for this post yet.
However, you are not allowed to reply to this post.