Reputation: 4952
Iam trying to set up mysql database connectivity in pycharm... I have already created the schema and it works in django etc... Iam trying to import the data source directly to pycharm but i get the following error...
Connection to Exception in thread "main" java.lang.ClassNotFoundException: com.mysql.jdbc.Driver
at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:186)
at com.intellij.persistence.database.console.RemoteJdbcServer.main(RemoteJdbcServer.java:15)
failed
What should i do to make the database connectivity possible??? i have downloaded the mysql jar file for the above class... How do i include it in pycharm??? (I have clicked the install drivers button that comes as a hint but nothing happens)... Thnx...
Upvotes: 3
Views: 9858
Reputation: 6691
In the properties of your MySQL connection, in the "General" tab, below the "Test Connection" button, you should see "MySQL" as a link next to "Driver: ". Click that. In the next screen, inside the white box below "Driver Files" it should have a "Download" link.
Upvotes: 3
Reputation: 401877
Check this video for the sample configuration steps, if you don't have a JDBC driver, PyCharm can download on for you.
Upvotes: 0