Issue 128035 - Can't use AOO with MariaDB and JDBC
Summary: Can't use AOO with MariaDB and JDBC
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: 4.2.0-dev
Hardware: All All
: P2 Blocker (vote)
Target Milestone: 4.2.0
Assignee: AOO issues mailing list
QA Contact:
Depends on:
Reported: 2019-02-09 16:08 UTC by Mechtilde
Modified: 2020-04-04 16:19 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: Medium


Note You need to log in before you can comment on or make changes to this issue.
Description Mechtilde 2019-02-09 16:08:33 UTC
I use AOO as a client for several databases. Most of them were originally created with MySQL. Now I use Mariadb on my Debian machines.

There is no MySQL JDBC Driver available. I get the message: "Can't load com.mysql.jdbc.Driver"

For using Mariadb there is an own JDBC Driver. The name of the driver class is org.mariadb.jdbc.Driver.

I found hardcoded entries: 

  67             prop[0] = new PropertyValue("JavaDriverClass", 0, "com.mysql.jdbc.Driver", PropertyState.DIRECT_VALUE);

 183                                                                         ,makeAny(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.mysql.jdbc.Driver")))

 234             ::rtl::OUString sDriverClass(RTL_CONSTASCII_USTRINGPARAM("com.mysql.jdbc.Driver"));
 354                                         ,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.mysql.jdbc.Driver"))

  41             <value>com.mysql.jdbc.Driver</value>

I think it is necessary to be able to use both entries.
Comment 1 damjan 2019-02-09 16:36:12 UTC
You can probably use the generic "JDBC" driver type and enter that class name there, but let's leave this bug open for adding native MariaDB support too.
Comment 2 Mechtilde 2019-02-10 11:03:38 UTC
for documentation

under Linux the class path is: /usr/share/java/mariadb-java-client.jar

The data source URL is: jdbc:mysql://<server name>/<database name>

If you want to edit data you must add "?useHostsInPrivileges=false"
Comment 3 Peter 2019-07-28 03:13:55 UTC
Is this still open?
Comment 4 Koray Durgut 2019-08-09 11:17:06 UTC
AtOmXpLuS : Everything in AtOmXpLuS.CoM
Comment 5 oooforum (fr) 2020-04-04 16:19:52 UTC
I have no problem to connect a MariaDB
I use this extension to have a native MySQL driver:

Maybe this could be integrated?