Bug 97146 - Mysql Databases only showing views, not tables in JDBC connection type with mariadb connector jar
Summary: Mysql Databases only showing views, not tables in JDBC connection type with m...
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Base (show other bugs)
Version:
(earliest affected)
5.1.0.1 rc
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-01-15 08:52 UTC by Tony
Modified: 2016-01-19 11:41 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tony 2016-01-15 08:52:14 UTC
Hi There

In addition to the other problem, the text colour in the table view in forms, I thought I'd try creating a new Base document from scratch.

I set the connection fine etc, and the connection to MySQL worked perfectly fine, but then here is the snag.

The MySQL databases have a number views, which show up in the Base table listing perfectly fine, however, none of the tables do??

The table does show, if I was to create a new table through the Base gui, but not of the pre-existing tables are viewable?

In a existing base database, last modified in LibreOffice 4.4, that connects to the same database, the tables can quite clearly be seen.
Comment 1 Alex Thurgood 2016-01-15 11:55:50 UTC
@Tony : how are you accessing the mysql instance, i.e. which driver combination are you using ?
Comment 2 Tony 2016-01-15 12:01:09 UTC
Hi there

I'm using the mariadb-java-client-1.1.8.jar in the classpath

And the DB connection is

mysql://localhost:3306/dbname

I've also tried with

mariadb://localhost:3306/dbname


Using MariaDB 10.0.15

On Centos 6
Comment 3 Alex Thurgood 2016-01-15 12:23:20 UTC
No repro on

Version: 5.2.0.0.alpha0+
Build ID: ac91a81b7b47fc9eba24455d34e2168309ea51d1
CPU Threads: 2; OS Version: -; UI Render: default; 
Locale: fr-FR (fr.UTF-8)

OSX 10.11.2

using mysql-connector-java-5.1.34

to a remote mysql 5.1 instance

My connection to the mysql server was created via the db wizard, using Connect to existing database, chossing mysql, then in the next step, selecting JDBC as the driver type.

Could be that it is your connector jar which is causing the problem, or else the type of connection setup in LO - how is it setup JDBC or MySQL (Wizard First step) ?

From your description, it sounds like you set this up directly as a JDBC connection, and not as a MySQL connection choosing JDBC as the connector type in the subsequent step.
Comment 4 Alex Thurgood 2016-01-15 12:25:59 UTC
I would add that my mysql instance has a db with both tables and views in it and I can see them all in my connection via LO
Comment 5 Alex Thurgood 2016-01-15 12:28:01 UTC
There were also some changes made in 5.1 dev with respect to filtering of tables in the code that only applied to mysql(jdbc) connection configurations, and not to JDBC connections in general - perhaps what you are experiencing is a rebound effect of those changes.
Comment 6 Tony 2016-01-15 19:52:30 UTC
Hi there

I've had a go, using the wizard. And that worked fine, I don't know, if anybody has noticed, but if after you have got the connection working, if you edit the connection, and take the database name out of the parameters, you get access to all databases that the connecting user has access to.

I hope that's by design, as that is an absolute bonus :-)
Comment 7 Alex Thurgood 2016-01-19 11:41:03 UTC
(In reply to Tony from comment #6)
> Hi there
> 
> I've had a go, using the wizard. And that worked fine, I don't know, if
> anybody has noticed, but if after you have got the connection working, if
> you edit the connection, and take the database name out of the parameters,
> you get access to all databases that the connecting user has access to.
> 
> I hope that's by design, as that is an absolute bonus :-)

Let's just say that it is an interesting side-effect :)

Per your comment, closing then as WFM