Issue
. I am still new to programming and I really don't know what else should I do, watched lots of Youtube videos but non of them work.
java.lang.ClassNotFoundException: com.mysql.jc.jdbc.Driver
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at RegisterForm.buttregActionPerformed(RegisterForm.java:458)
at RegisterForm.access$300(RegisterForm.java:24)
at RegisterForm$4.actionPerformed(RegisterForm.java:153)
I have already made a database and also the table in the localhost, when it I press the register button it won't store the user inputted.
Class.forName("com.mysql.jc.jdbc.Driver");
con = DriverManager.getConnection("jdbc:mysql://localhost:3306/userinterface_?serverTimezone=UTC","root","");
ps = con.prepareStatement("INSERT INTO 'java_login_register'('fname', 'lname', 'uname', 'pass','gender','phono',bdate','address') VALUES (?,?,?,?,?,?,?,?)");
Above is my code to store the user inputted to the database. ineedhelp
Solution
i think you connection string is an problem , try to the reference Website
Answered By - Uday