• Register
search
Log In
0 votes
216 views

Problem :

I am getting bellow error while I try to connect MySql database with Java using connector 8.0.11

java.sql.sqlnontransientconnectionexception: public key retrieval is not allowed

6.9k points

1 Answer

0 votes

Solution:

I also faced above error , in my case it was actually due to the wrong username and password. 

Solving the issue: 

a. Go to the line DriverManager.getConnection("jdbc:mysql://localhost:3306/?useSSL=false", "username", "password"); 

b.The fields username and password must be wrong. You must enter the username and password which you use to start your mysql client. 

Further Readings:

https://github.com/speedment/speedment/issues/621

36.1k points
edited by

Related questions

0 votes
2 answers 56 views
56 views
Problem : I am getting bellow error while trying to execute JDBC code java.sql.sqlexception: operation not allowed after resultset closed
asked Nov 1, 2019 peterlaw 6.9k points
0 votes
1 answer 165 views
165 views
Problem : I am updating values using JDBC but getting bellow error java.sql.sqlexception: column count doesn't match value count at row 1
asked Oct 31, 2019 peterlaw 6.9k points
0 votes
1 answer 83 views
83 views
Problem : I am getting bellow error java.sql.sqlexception lock wait timeout exceeded try restarting transaction I am using Java Struts 2.1 Hibernate configuration. DB Used is MYSQL. Anyone know how to solve it..??
asked Oct 23, 2019 peterlaw 6.9k points
0 votes
1 answer 261 views
261 views
Problem : I want to input some of the details about student to my program. But when I press a save button its giving me the below listed exception error: "Exception in thread "AWT-EventQueue-0" java.lang.UnsupportedOperationException: Not supported yet."
asked Jan 31 jwilliam 3.9k points
0 votes
1 answer 618 views
618 views
Problem : When I try to run the below code: j=0 while j<5: j=j+1; try: MySellSta=client.get_order(symbol=MySymb,orderId=MySellOrderNum,recvWindow=MyDelay) except client.get_order as mye: print ("This is the error message!{}".format(j)) #End while I got the following error ... #End while The result is that it ignores my error and go to my next while but I want to catch my error and print my error.
asked Dec 27, 2019 alecxe 7.5k points