5
जेडीबीसी के साथ mysql डेटाबेस से कनेक्ट होने पर मुझे यह त्रुटि मिल रही है।जेडीबीसी कनेक्शन त्रुटि: अपरिचित समय क्षेत्र
Database.getConnection() Error -->The server time zone value 'EEST' 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.
यह मेरा कनेक्शन कोड है।
public static Connection getConnection(){
try {
Class.forName("com.mysql.jdbc.Driver");
Connection con = DriverManager.getConnection(
"jdbc:mysql://localhost:3306/management", "root", "root");
return con;
} catch (ClassNotFoundException | SQLException e) {
// TODO Auto-generated catch block
System.out.println("Database.getConnection() Error -->"
+ e.getMessage());
return null;
}
}
त्रुटि संदेश पर्याप्त स्पष्ट है। क्या * ठीक * आप इसके बारे में नहीं समझते हैं? – Raedwald
SO, क्या आपने सर्वर समय-क्षेत्र को सही करने का प्रयास किया है? –
मुझे सर्वर टाइमज़ोन कॉन्फ़िगरेशन प्रॉपर्टी नहीं मिली। – mcemilg