I used Mathematica to access the data of a MariaDB MySQL database. Within the version 12.0 it worked well on linux using the following code:
Needs["DatabaseLink`"]
conn = OpenSQLConnection["OpenHAB"];
I defined the connection properties successfully like this:
- User Lever
- MySQL(Connector/J)
- com.mysql.jdbc.Driver
- jdbc:mysql://
- IP, port, username, password
After switching to Mathematica 12.2 everything works fine just after fresh installation.
After the second start of Mathematica the connection gets the following error:
KeyExistsQ::invrl: The argument Association[Flatten[JDBCDrivers[]/. JDBCDriver[Name->DatabaseLink`SQL`Private`name_,Driver->DatabaseLink`SQL`Private`driver_,Protocol->DatabaseLink`SQL`Private`protocol_,_,_,_]:>{DatabaseLink`SQL`Private`name->Association[Rule[<<2>>],Rule[<<2>>]]}]] is not a valid Association or a list of rules.
From the second start on I can not bring the connection back on line. If I use the assistant under
OpenSQLConnection[]
to delete the connection and to set it up again it will fail also. If I use the Test button within the assistant I get
Error:KeyExistQ::invrl
The only way to bring the connection back at least once is to uninstall Mathematica completely and do a fresh install. As this works until the next start of Mathematica it is not a very suitable for working.
Thanks