Je dois effectuer deux requetes distinctes :
Code : Tout sélectionner
$sql = "SELECT tab1.id, tab1.date, tab2.nom, tab2.prenom FROM tab1 LEFT JOIN tab2 ON tb1.id = tb2.id ORDER BY tb1.date DESC";Code : Tout sélectionner
$sql = "SELECT tab1.id, tab1.date, tab3.nom, tab3.prenom FROM tab1 LEFT JOIN tab3 ON tb1.id = tb3.id ORDER BY tb1.date DESC"; $data1 = array();
$data2 = array();
while ($data = mysql_fetch_assoc($req1)){
$data1[] = $data;
}
while ($data = mysql_fetch_assoc($req1)){
$data2[] = $data;
}
Pourriez-vous m'aider à faire ma sortie ?Je voudrais afficher par mois (la date est un timestamp)
Code : Tout sélectionner
mois avril
id - nom - prenom
mois mai
id - nom - prenomDonc il y'a des doublons et je ne parviens pas à afficher par mois.
Pouvez-vous m'aider ? D'avance merci.