table slabpay
-------------------------------------------------------
agent_id|agent_name|cust_id|cust_name|installment_amt|
-------------------------------------------------------
1 |mike |1 |john |350 |
-------------------------------------------------------
1 |mike |1 |john |400 |
------------------------------------------------------
1 |mike |2 |abraham |350 |
-------------------------------------------------------
1 |mike |1 |john |450 |
-------------------------------------------------------
1 |mike |2 |abraham |400 |
-------------------------------------------------------
mysql query
------------------------------------------------------
`$select = mysql_query("SELECT cust_id, cust_name,installment_amt FROM slabpay WHERE agent_id=1");`
result should be
------------------------------------------------------
cust_id | installment_amt
-------------------------------------------------------
1,john ,350,400,450
2,abraham ,350,400
------------------------------------------------------
i am new to php mysql please help me to solve this problem