I have a mysql database that collects application forms. Each application form gets copied into the DB.
Example :
ID l Username
01 MW001
02 MW002
03 MW001
04 MW001
I want to get the value of the duplicates in a number by using a session as they login to there account a session gets created where i currently show them all there details , example
MW001 has 3 applications If i could get the full query and how to display it, this is what i used.
$sql = "SELECT affID, COUNT(*) FROM taffiliate WHERE affID = '" . $_SESSION['affID'] . "'";
$result = mysql_query($sql);
$row = mysql_fetch_array($result);
echo $row['affID'] ;
In short i just want to show them they applied 3 times.