Bonjour,
Voici une requête qui fonctionne bien
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
select c.id, c.nom, c.commentaire,  e.nom, t.nom, GROUP_CONCAT(t.nom SEPARATOR '<br/>') AS liste_test
from tblcours c
left join tbltest t on t.id_cours = c.id
left join tblcoursdetail b on b.id_cours=c.id
left join tbladherent e on e.id = b.id_createur
 
where c.id_activite=2 and e.nom LIKE '%bastien%'
 
group by c.nom;
Cependant, je voudrai que réalise un tri sur le champ c.nom

J'ai bien proposé
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
select c.id, c.nom, c.commentaire,  e.nom, t.nom, GROUP_CONCAT(t.nom SEPARATOR '<br/>') AS liste_test
from tblcours c
left join tbltest t on t.id_cours = c.id
left join tblcoursdetail b on b.id_cours=c.id
left join tbladherent e on e.id = b.id_createur
 
where c.id_activite=2 and e.nom LIKE '%bastien%'
order by c.nom asc
group by c.nom;
mais j'ai une erreur

Pourquoi?

Merci