studentview + modif BDatabase

This commit is contained in:
brinet
2022-12-01 17:12:25 +01:00
parent 14ebaedeeb
commit 16a83ebdbd
15 changed files with 140 additions and 7 deletions

View File

@@ -255,12 +255,16 @@ public class BDatabase {
* Recupere le nombre d'etudiant par groupe
* @return
*/
public ArrayList<NBGroupe> getNbrEtuGroupes() {
ArrayList<NBGroupe> NGroupe = new ArrayList<>();
ArrayList<String> groupeNB = this.fetchAll("SELECT COUNT(DISTINCT groupe) FROM fi_eleves;");
for(int i = 0; i <= NGroupe.Goupe(groupeNB); i++) {
ArrayList<String> grpnb = this.fetchAll("Select count(id) from fi_eleves where groupe="+i+";");
/**
* Recuperer le nombre de membre d'un groupe
*
* @param groupe_id le groupes
* @return le nombre de membre
* */
public int getMemberCount(int groupe_id) {
ArrayList<String> forCount = this.fetchAll(
"SELECT nom FROM fi_eleves WHERE groupe=" + groupe_id);
}
}
return forCount.size();
}
}