Do database exchanges between MacOS and Windows versions require Rebuild Indexes?

I’ve just experienced twice that a RM9 database from an iMac running Ventura fails on Windows RM9 Database Tools => Test Integrity with many indexing errors. Are others seeing the same?

More here:

image
…about 100 such “missing…” errors in this relatively small file (<4000 people).

Either tool Rebuild Indexes or Compact clears up the problem. Without doing so runs some risk of failures on operations that find or sort or match values.

1 Like

Confirming that I had the same result.

1 Like

@kevinm has confirmed with his Mac and Windows computers that a RM database file getting OK on Test Integrity on one OS fails that test in the RM Version on the other OS (both RM 9.0.2), regardless of the transfer direction. Rebuild Index corrects the problem in both cases.

In the ongoing discussion at https://sqlitetoolsforrootsmagic.com/forum/topic/a-different-rmnocase-in-the-mac-version/, we think this is due to either:

  • The proprietary RMNOCASE collation sequence used for string comparisons for name-type database fields for sorting and matching is different between the original one for Windows and the recent one for Mac

OR

  • The SQLite database engine in the Mac version interprets the identical RMNOCASE collation sequence differently from the SQLite database engine in the Windows version.

Regardless, the outcome of a transfer of a database file from one OS to the other results in an interoperability issue with potential adverse side effects unless the user takes corrective action by using either of the RM Database Tools: “Rebuild Indexes” or “Compact”.

These findings may indicate that for certain Unicode characters, RM on the two platforms will sort them in different order and possibly match them differently. That would seem to be confusing and undesirable.

Without exploring the semantics of calling it a “bug”, I’m sure this outcome is unintentional and deserves some attention:

  • At the very least, the Help system should say something about transferring between Mac and Windows platforms.

  • Better would be that the database carry within it an indicator of which platform carried out the last Reindex or Vacuum operation and that the application detect it on opening and REINDEX if different.

  • Best would be that the platforms be made to collate identically

@rzamor1

1 Like

Interesting. I haven’t done it with RM9 but that didn’t used to be the case. When I was still on RM7.7 (which I was until right before RM9 came out) I was moving back and forth with some regularity. I will need to experiment.

1 Like

With RM7, it is the Windows app in a wrapper so the collation sequence is definitely the same and the wrapper interacts with it as Windows through the same SQLite compilation. With RM9, it’s definitely a different compilation of presumably identical source code interacted with via a different OS and, possibly, the collation sequence is itself defined differently.

So I await your observation with interest!

happens to me too in RM9 (as it did in RM8).
As you say, reindex definitely a good idea as soon as opened, whichever end of the open you are on, Win or Mac.
Now on Ventura, also when I was on Monterey.

3 Likes