Porting database to 5.3

Please note: currently using on Mint 18 with LO v5.3.2.2 and not v4.3!

I am not doing anything unusual. No macros, no events. I think I will create a very simple test DB in the old system and see if it to will not read in the new version and report back.

Yes, that makes a difference. When you first open this .odb, in the lower left corner does it state Embedded database? If so, by any chance, in your LO v4.2.8.2 did you have any additional paths set?

OK, I created a very simple 5 field 1 record database in the 4.1 LO base. Moved it over and it plays fine. I am not sure that proves anything other than you can port. Obviously it does not like something in my larger 540 record database. One thing I do is link images but I did move over the image directory in the same path under the database. It would be great if there was some kind of test for a database for any possible errors. This might be very hard to find. Any tips on what to do?

Yes, in answer to your question it does read embedded database. Am I out of luck because of that? What determines an embedded database when it is created? I am not storing any photos in the database at least I don’t think so . I started out doing that an quickly realized it was not a good idea and deleted that field and went to linked photos. Maybe I should copy the database and try deleting the photo links?

Linked images would not create a problem. Embedded would be a big problem. The next thing I would try is to split (you did say this was embedded) out the database. On this post (click here, in my answer, I have created a procedure to take a broken DB and possibly create a working split DB from it. It is not difficult. Just follow step-by-step and use a COPY of your odb

FYI - An embedded DB means that the data is zipped into the .odb file when closed and unzipped when the .odb is opened. This is a potential for trouble as this process has been known to corrupt data. A split DB will greatly reduce this type of problem as the data is resident in its own sub-directory. This is similar to other DB’s such as MySQL and PostgreSQL where data is stored separately. Should the above split work, I suggest you retain that set-up.

Thank you very much for your answer and help. The current database is not broken at least not in the old 4.1 environment but I will split it and try and get it working on 5.3. I can practice on a copy and not mess with the one that is working. Unfortunately I won’t get to this until Sunday at the earliest but I will get back with a result. Thanks again.

One other quick questions. How does a database get embedded to begin with? Was it an option I selected at creation or was that the standard back then?

LO Base even now, come with, and uses by default, the HSQLDB v1.8 (somewhat outdated) embedded database. This is OK for learning, small DB’s and posting samples. When dealing with important information or large amounts of data, many switch to , minimally, a split DB. Others, like myself, use an external DB such as MySQL, PostgreSQL, SQLite or Debian. There is a current project to switch to the Firebird embedded DB (available currently under experimental features).

To add to what Ratslinger said, I just noticed that the next version of Debian Linux called Stretch, or 9.0, and scheduled for release today (and upon which many other distros are based, e.g. Ubuntu) will now default to MariaDB 10.1 rather than MySQL. Yes, they are close cousins, but if you were to start out today you might want to start with MariaDB rather than MySQL.

Thanks for clearing up about the embedded database. Question - the latest split wizard hsqldb.jar v2.3.2 has both hsqldb.jar and sqltool.jar built-in. Do these two files still need to be in the driver directory?

I forgot exactly how it works. Just ran a quick test. It does already places those in the driver directory. That is all you need.

I actually had to create a driver directory and copy them there for it to work. Otherwise it complained it could not find them. Now the next problem. It is complaining about an error in the script. It is not that long but I don’t think it will fit in a comment. How do I transfer that file to you so you can look t it?

The exact errors -

The connection to the data source “Split_HSQLDB_2.3.2_Wizard_v3d” could not be established.
SQL Status: S1000
Error code: -25
error in script file line: /home/doug/Documents/CHS68_split/database/CHS68-split 3

I have given you some karma. You can post a copy of your file in your question.

Thanks - added.

Nothing seems to be liking your file. I have found a problem from a while back with HSQL and a similar error. It does not help your situation. Here is my last suggestion. Create a new empty Split DB. Create a new directory. Place a copy of the wizard within. Run the wizard to create a new split DB.

Now open your embedded DB using LO v.4.2 which you said works. Copy the table from the old embedded & paste into new split. Then see if you can open the table in the new split DB.

OK - before I do that there is something I did not tell you . I am trying to do this split in the 4.2 code. I can easily move the directory over to a 5.3 system and try again there. That might be the problem?

No, that won’t make any difference. The split DB is using its own HSQL (in driver directory). The Embedded is using the HSQL in LO 4.2. The problem seems to lie in the 4.2 HSQLDB. What I am hoping to get around here is the script problem. By doing this process, the split should create a new script for the copied table.