Reading
Add Comment
mysql:driver not found:
Problem:
I was missing port number I am using url "jdbc:mysql://localhost/db" that url was execting and can access database when it runs sepratly from jsp, while it causing error when it execute at tomcat server with jsp.
Solution.
So to resolve this problem .
At jsp use "<% Class.forName("com.mysql.jdbc.Driver"); %>"
and in java bean class instead of using "jdbc:mysql://localhost/db" use the following url:
"jdbc:mysql://localhost:3306/db"
0 comments:
Post a Comment