public void sqlConnect() {

        try {
            Class.forName("com.mysql.jdbc.Driver").newInstance();
            conn = DriverManager.getConnection(url, user, password);
            //if (!conn.isClosed()) {
                //System.out.println("connect to Database successfully!");
            //}

            stat = conn.createStatement();
        } catch (Exception e) {
            e.printStackTrace();
        }
    }