Guest User

Untitled

a guest
Mar 29th, 2018
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.55 KB | None | 0 0
  1. import java.sql.Connection;
  2. import java.sql.DriverManager;
  3.  
  4. Connection conn ;
  5.  
  6. //the Driver I'd ultimately like to see working
  7. //Class.forName("org.apache.phoenix.jdbc.PhoenixDriver");
  8.  
  9. //testing with mysql jar - this line works fine
  10. Class.forName("com.mysql.jdbc.Driver");
  11.  
  12. //the connection that throws:
  13. //"java.sql.SQLException: No suitable driver found for jdbc:mysql://localhost:3306/lportal-71x-private"
  14. try{
  15. conn=DriverManager.getConnection("jdbc:mysql://localhost:3306/lportal-71x-private", "root", "test");
  16. } catch(Exception e) {
  17. out.println(e);
  18. }
Add Comment
Please, Sign In to add comment