Bug 114794 - LibreOffice will no longer recognise my Access database
Summary: LibreOffice will no longer recognise my Access database
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
5.3.7.2 release
Hardware: x86-64 (AMD64) Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: possibleRegression
Depends on:
Blocks: Database-MS_Access
  Show dependency treegraph
 
Reported: 2018-01-01 19:09 UTC by Chris Grove
Modified: 2018-03-20 08:50 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
odb database file which ought to connect to KITS2 (4.06 KB, application/vnd.sun.xml.base)
2018-01-02 17:42 UTC, Chris Grove
Details
Access .mdb databse file to which KITS3 should connect (1.13 MB, application/msaccess)
2018-01-02 17:44 UTC, Chris Grove
Details
Screenshot MSAccess error message (30.94 KB, image/png)
2018-01-03 08:58 UTC, Jean-Pierre Ledure
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Grove 2018-01-01 19:09:58 UTC
Description:
One last effort to get LibreOffice Base working again, otherwise I may be compelled to find another program.  During previous efforts, it has been suggested that I have not always provided the detailed information that the very patient responders could have used to solve my problem; this time I will do my best to tell you everything.

Towards the beginning of December, I was happily updating my database, which is a LibreOffice Base database (entitled REFS3) but based on a Microsoft Access (mdb, not 2016) database (entitled REFS2), when LibreOffice stopped responding.  In the past, I have always found that this indicates that an update is available, so I updated LibreOffice - to version 5.3.7.2 x64.  From that moment, though I can open the opening screen of REFS3, as soon as I select a table (or query or report), all I get is a pop-up window stating ‘The connection to the data source REFS3  could not be established.  The connection could not be created.  Perhaps the necessary data finder has not been installed’.

On seeking help, I was told that LO 5.3.7.2x64 is a 64 bit version and therefore requires a 64 bit Java JRE.  So I upgraded Java to Oracle version 1.8.0_151 which I am assured is a 64 bit version.  After several more days of effort, I managed to get the JRE which Java said was installed to appear on the LO Java Options screen (Tools, Options, Advanced), and further that the Parameters screen and the Class Path screen are both empty.  I have ensured that both databases REFS3 and REFS2 are registered, that Microsoft Access and the correct address of the REFS2 database appear at the bottom of the opening screen of REFS3,  that REFS2 and REFS3 are both set to open with LO Base.

But despite all this advice and action, all I get when I open REFS3, and select a table, is that pesky pop-up window mentioned above

What I have not altered is the LO /tools/options/LibreOffice Base Connections screen.  The current connection is com.sun.star.comp.sdbc.ODBCDriver.  Connection pooling is enabled, but pooling is set to NO on all the entries.  The problem is not fixed by going into Safe Mode.

If anyone can advise me on how to get my database working again, I would be very grateful.  Actually, I have three similar databases, but this one is the most complex (three tables) and if this one gets fixed, I reckon I will be able to sort out the other two.

Steps to Reproduce:
1.Enter LibreOffice
2.Select REFS3 database
3.Select any table, query or report

Actual Results:  
The pop-up window described above appeared

Expected Results:
The appearance of the table.query/report on screen


Reproducible: Always


User Profile Reset: No



Additional Info:
[Information automatically included from LibreOffice]
Locale: en-US
Module: StartModule
[Information guessed from browser]
OS: Windows 10 Home
OS is 64bit: yes
Version: 5.3.7.2 (x64)
Build ID: 6b8ed514a9f8b44d37a1b96673cbbdd077e24059
CPU Threads: 4; OS Version: Windows 6.19; UI Render: GL; Layout Engine: new; 
Locale: en-GB (en_GB); Calc: group


User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:57.0) Gecko/20100101 Firefox/57.0
Comment 1 Chris Grove 2018-01-01 19:39:56 UTC Comment hidden (off-topic)
Comment 2 Adolfo Jayme Barrientos 2018-01-02 04:07:14 UTC Comment hidden (off-topic)
Comment 3 Julien Nabet 2018-01-02 09:58:53 UTC Comment hidden (obsolete)
Comment 4 Jean-Pierre Ledure 2018-01-02 16:09:09 UTC
@ Chris Grove

Could you please attach the REFS3 and REFS2 database files (or any other test case that has the same issue) ?
I will not be able to reproduce the incident without them.

Thanks in advance.
Comment 5 Chris Grove 2018-01-02 17:23:33 UTC
REFS 2 is now nearly 24 Mb and I think it somewhat overkill to send all that to you.  What I will do is to ensure that another database using KITS3 and KITS2 (only just over 1 Mb) is at the same state as the REFS databases and send you that.  Same problem, though a much smaller and simpler database (2 tables not linked).  As before KITS3 is the .odb and KITS2 is the .mdb.  Wait while I do that.
Comment 6 Chris Grove 2018-01-02 17:42:49 UTC
Created attachment 138816 [details]
odb database file which ought to connect to KITS2

Since I reported this bug, the list of registered databases has disappeared leaving only my Bibliography showing.  Should I reregister my databases, and , if so, which ones - odb, mdb or both?
Comment 7 Chris Grove 2018-01-02 17:44:51 UTC
Created attachment 138817 [details]
Access .mdb databse file to which KITS3 should connect
Comment 8 Jean-Pierre Ledure 2018-01-03 08:58:42 UTC
Created attachment 138840 [details]
Screenshot MSAccess error message
Comment 9 Jean-Pierre Ledure 2018-01-03 09:02:21 UTC
I could reproduce the problem in LO 5.4.3.2 under Win7 (x64).

However, when I tried to open KITS2.mdb with MSAccess itself, I got the error message stored in the attached screenshot. This could explain, maybe, that the sdbc driver gets stuck.

Of course, only if you get the same message, Chris, if you try to open the same .mdb in your environment.

Can you please report on this ?
Thanks.
Comment 10 Jean-Pierre Ledure 2018-01-03 09:06:28 UTC
(In reply to Chris Grove from comment #6)
> Created attachment 138816 [details]
> odb database file which ought to connect to KITS2
> 
> Since I reported this bug, the list of registered databases has disappeared
> leaving only my Bibliography showing.  Should I reregister my databases, and
> , if so, which ones - odb, mdb or both?

I doubt registering the database could solve the problem.
Anyway, only odb's should be registered. It does not make sense to register an mdb.
Comment 11 Chris Grove 2018-01-03 11:33:30 UTC
Jean-Pierre
Many thanks for your attention. I do not have MSOffice installed, so I cannot access the .mdb databases direct.  If I access it/them through LO, I get the pop-up window as described above.  Ability (which I installed in desperation to get some access to my data) can access the tables in REFS2 and KITS2 (but I guess my queries and reports will have to be rewritten in 'Ability-speak' which I have not attempted) without any problems.  I have verified with Ability that their program does not alter the .mdb file format.
Comment 12 Chris Grove 2018-01-04 12:07:04 UTC
Just another thought.  The database KITS2, back in the days when I was actually using MSAccess as my database, used to have a password required to enter it.  This has not been requested ever since I changed to LO, but the file KITS.ldb is still there.  I could attach it if you think that could be the cause of the problem.  However, it has been so long since I needed it that I have forgotten what the password was, but it might have been PANZER.

The REFS2 database also had a password PANZER.  When I changed to LO, I was indeed asked for this password every time I entered the database, up till the time that I updated to LO 5.3.7.2, since when I have not been asked.

Probably a silly question, but should the odb file be looking at the ldb file and not the mdb one?

Chris
Comment 13 Chris Grove 2018-01-04 20:17:55 UTC Comment hidden (obsolete)
Comment 14 Jean-Pierre Ledure 2018-01-05 10:16:29 UTC
(In reply to Chris Grove from comment #13)
> If I try to access .mdb files  direct, I get a LibreOfffice Writer document
> which starts ####Standard Jet DB##### followed by an unintelligible series
> of, often unusual, characters.
> 
> If I access .ldb files direct, I get another Writer document which says
> DESKTOP-E1AT4QK# (that is for KITS2.ldb) then a number of spaces and then
> Admin#
> 
> Chris

This is not relevant with the discussed issue: LO is not prepared to open .mdb or .ldb files directly. When LO is invited to open an unknown format, it always tries to open it with Writer combined with one of the many builtin format convertors. If the format is not supported it gives unpredictable results like the one you observed.
Comment 15 Jean-Pierre Ledure 2018-01-05 10:39:29 UTC
I could reproduce the incident with Win7/LO 5.4.3.2.
I got the same error message as described earlier while setting up a new Base document linked to an own MSAccess database (.mdb format). I tried both the "SDBC/Microsoft Access" and "ODBC/Microsoft Access" drivers.

(Note that accessing a .accdb database with the "SBDC/Microsoft Access 2007" driver worked fine.)

I changed to status of the bug to NEW.

My conclusion is that there was indeed a regression some time before LO 5.3.7. Some components were not included in the build anymore ?
But identifying which commit could have been the cause of it is very far from my competences.
Comment 16 Chris Grove 2018-01-05 12:29:57 UTC
Thankyou for your efforts, Jean-Pierre.  You may well be right, but I was accessing and updating my database immediately before updating LO!
Chris
Comment 17 Robert Großkopf 2018-01-05 18:34:00 UTC
Have never used Access and *.mdb. Only one idea: Isn't *.mdb a database for 32bit? Could this be the problem? 6bit LO, 64bit Java and 32bit *.mdb-file?

See also
https://bugs.documentfoundation.org/show_bug.cgi?id=97395
Comment 18 Chris Grove 2018-01-05 20:08:21 UTC
Well; I suppose that could be the problem. Until I updated my LO, I had never bothered with the difference between 64 bit and 32. But 64 bit LO still offers you the possibility of connecting to  an .mdb file.  If it can't work, then perhaps it should not offer it as a possibility.  Maybe I'll have to go to Ability after all.  Chris
Comment 19 Jean-Pierre Ledure 2018-01-06 13:13:57 UTC
The .mdb format for MSAccess databases is not related to 32/64 bits. It is related to the version: .mdb <= 2003, .accdb >= 2007.
Note that MSAccess >= 2007 support both internal formats.

I could open the KITS3.mdb file under Win7(x64) with MSOffice 64 bits.

But I could not open any *.mdb file from LO 5.4.3.2 (64 bits still under Win7). My conviction remains that the proposed MSAccess driver in LO does not work correctly anymore (or is not correctly installed ... ?).
LO - even 64 bits version - should be able to open an uncorrupted .mdb file. It it is not, then it is a bug.
Comment 20 Stang 2018-02-12 03:56:33 UTC
Saw this bug today and felt somewhat responsible.  I originally answered Chris Grove on the ask.libreoffice site.  At the time I wasn't aware the Access connection does not work in Windows 64-bit.  Recent activities have brought this to light.

I am posting because there is a way to do this in 64-bit if you use a JDBC connector - UCanAccess.  Have posted the "How To" steps here:

    https://ask.libreoffice.org/en/question/145877/mdb-files-not-loading-to-base/

Sorry for any inconvenience & hope this helps.

I also believe this is still a bug, but for now there is another way without going to 32-bit.
Comment 21 Chris Grove 2018-03-13 15:48:33 UTC
Hi all
Many thanks for numerous suggestions, some very useful and some not quite so useful.  Stang's suggestion worked  to get the database working again, but I still had the problem of passing the required parameter into the database in order to create the report I needed.  However, from elsewhere I got a suggestion to create a single record table containing that parameter, and connect that into the database, and that finally got it to work and create a usable report for me!
Comment 22 Zineta 2018-03-19 14:54:28 UTC
I tested in LO 5.3.7.2 with no error message.I could even edit tables kits1 and models1.
OS: Win 7
Java Update 71(64-bit)  8.0.710.15
Comment 23 Chris Grove 2018-03-19 20:08:20 UTC
Thanks to everyone for their efforts on my behalf.  A suggestion (from the Ability helpline) to use a single record table to pass the vital parameter to the report has worked.  I am now able to create a usable report from my databases, using either LibreOffice Base or Abiity.  I suspect I will have to go through the process proposed by Stang above in order to access the Kits database in LO, but I can use that in Ability without problems.

Since, in the past, the crashing of LO Base has indicated to me that an update needs to be done, I shall await the next update with interest!

Chris
Comment 24 Timur 2018-03-20 08:50:04 UTC
Based on from I understood here, I'll close as WFM. 
Because open bug needs to have problem and required solution. 
And here we had a problem and some workaround, but no requirement for a solution.
I suggest that issue is discussed in See also bugs.