[wd_asp elements=’search’ ratio=’100%’ id=1]

Select Distinct (with other fields)- Group by

14th August 2013

MySql

mysql codehaven category

To only select distinct client, use group by not distinct, unless you are only looking for one field.
$result = mysql_query("SELECT client,campaign,month FROM data WHERE time='14' group by client ORDER BY client ASC");