public Epreuve getNomCatEpreuveEq(int IdEp) throws DAOException {
String req = String.format(reqNomCatEpreuveEq, IdEp);
Connection conn = null;
Statement stmt = null;
ResultSet result = null;
Epreuve nomCatEpreuveEq =new Epreuve();
try {
synchronized (dataSource) {
conn = dataSource.getConnection();
}
stmt = conn.createStatement();
System.out.println(req);
result = stmt.executeQuery(req);
while (result.next()) {
nomCatEpreuveEq.setNomEtCategorie(result.getString(2), result.getString(3));
// nomCatEpreuveEq = new Epreuve(result.getString(1), result.getString(1));
// nomCatEpreuveEq.getNom()= result.getString(2);
// nomCatEpreuveEq.getCategorie();
//nomCatEpreuveEq.add(new Epreuve(result.getString(2), result.getString(3)));