public void SQLconnect() {
try {
  System.out.println("Connecting to MySQL database...");
  Class.forName("com.mysql.jdbc.Driver").newInstance();
  String conn = "jdbc:mysql://" + this.SQL_HOST/* + ":" + this.SQL_PORT */
      + "/" + this.SQL_DATA;
  this.con = DriverManager
      .getConnection(conn, this.SQL_USER, this.SQL_PASS);
} catch (ClassNotFoundException ex) {
  System.err.println("No MySQL driver found!");
} catch (SQLException ex) {
  System.err
      .println("Error while fetching MySQL connection!");
} catch (Exception ex) {
  System.err
      .println("Unknown error while fetching MySQL connection.");
 }
}
This is java, Can I use the connection "con" to connect to my MySql database from different threads? Or is this not thread safe.
And if its not thread safe, How should I do this?