SHARE
TWEET

Untitled

a guest Jul 16th, 2019 99 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. java.sql.SQLException: The server time zone value 'CEST' is unrecognized or represents more than one time zone. You must configure either the server or JDBC driver (via the serverTimezone configuration property) to use a more specifc time zone value if you want to utilize time zone support.
  2.      
  3. private  String CONN_STRING = "jdbc:mysql://localhost:3306/vmenginedatabaseT04P/"; // "jdbc:mysql://localhost:3306/vm_database_1";
  4.  
  5.     private boolean connected ;
  6.  
  7.     private Connection connection;
  8.  
  9.     public boolean isConnected() {
  10.         return connected;
  11.     }
  12.  
  13.  
  14.     public Connection Connect()
  15.     {
  16.         Connection conn = null;
  17.         try {
  18.             Class.forName("com.mysql.cj.jdbc.Driver");
  19.             conn = DriverManager.getConnection(CONN_STRING,USERNAME,PASSWORD);
  20.             System.out.println("Connected");
  21.             connected = true;
  22.             return conn;
  23.         }catch (SQLException e){
  24.             System.err.println(e);
  25.         } catch (ClassNotFoundException e) {
  26.             e.printStackTrace();
  27.         }
  28.         return null;
  29.     }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top