static void connect () {
try {
Class.
forName ("org.gjt.mm.mysql.Driver");
"jdbc:mysql://localhost:3306/mysql");
}
System.
out.
println ("SQL exception:" + sqle.
getMessage ());
System.
out.
println ("SQLState:" + sqle.
getSQLState ());
System.
out.
println ("VendorError:" + sqle.
getErrorCode ());
}
catch (Exception sqle
) {sqle.
printStackTrace ();
} }