public List<Student> getAllStudents() throws SQLException{
   List<Student> mylist= new ArrayList();  
        try {
            MyConnection mc=new   MyConnection();
           dbConnection=mc.getConnection();
           statement = dbConnection.createStatement();
                 
                 String selectTableSQL = "SELECT * FROM school.student";
                 ResultSet rs = statement.executeQuery(selectTableSQL);
 
               
                 while (rs.next()) {
                     Integer sId=rs.getInt("id");
                     String sName=rs.getString("name");
                     String sAddress=rs.getString("address");
                    // Date hireDate=rs.getDate("HIRE_DATE");
              
                     
 Student e=new Student(sId,sName,sAddress);

 
				System.out.println("Student ID : " + sId);
				System.out.println("Student NAME : " + sName);
                              
mylist.add(e);
			}
                 
        } catch (SQLException ex) {
          System.out.println(ex.getMessage());
        }
        finally {
 
			if (statement != null) {
				statement.close();
			}
 
			if (dbConnection != null) {
				dbConnection.close();
			}
 
		}
        return mylist;
}