$say=mysql_query("select count(id) as toplam from telefon group by il"); while($rows=myslq_fetch_assoc($say)){ echo $rows['toplam']; }