I have a database (called "socializer") residing within MariaDB server and I'm trying to generate JPA entities from tables of that database in Eclipse, but cannot, because schema selection is grayed. Any ideas why?
My setup: Eclipse Neon, Eclipse Link 2.5.2, MariaDB 10.1.19-1, Arch Linux.
I know that the connection to my database has been established, because I can see it listed in Data Source Explorer, but its "Schemas" folder is displayed just empty, although it actually contains a few tables, created and perfectly observed within MySQL Workbench (the other listed databases appear to have empty "Schemas" as well).
JDBC connection properties:
Database: "socializer"
URL: "jdbc:mariadb://localhost:3306/socializer"
User name: root
Password: ""
JDBC driver (Generic JDBC Driver, mariadb-java-client-1.5.5.jar) properties:
Connection URL: "jdbc:mariadb://localhost:3306/socializer"
Database Name: "socializer"
Driver Class: "org.mariadb.jdbc.Driver"
User ID: "root"
And yes, user name and password are ok (ping will fail if either of them is changed).
In Addition to the comments, I found another reason that might cause the problem, that no schema's are listed:
I run into this while trying to connect to another database with other schemas than before.
Go to Project -> Properties -> JPA and disable/uncheck Override default schema from connection
If there is a schema selected that doesn't exist in the selected database, no schemas will be shown when creating entities. For me the problem was, that Eclipse was trying to show a schema from the database before.
In my case my database name was not case sensitive.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With