ajout .gitignore + modif makefile et BDatabase.java

This commit is contained in:
brinet
2022-12-01 16:02:29 +01:00
parent c40366e4e2
commit 14ebaedeeb
3 changed files with 23 additions and 1 deletions

View File

@@ -251,4 +251,16 @@ public class BDatabase {
public String toString() {
return this.db_host + "\n" + this.db_name + "\n" + this.db_user + "\n";
}
/***
* 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+";");
}
}
}