mi dà un errore che non capisco:Originariamente inviato da fabi080
Prova così
codice:SELECT utente_id, count(utente_id) as presenze WHERE MONTH(data_id) = '$id_mese' AND YEAR(data_id) = '$hid_anno' GROUP BY utente_id
You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE MONTH(data_id) = '1' AND YEAR(data_id) = '2005'