$command= “SELECT count(distinct username) as allusername from tablename “;
$result = mysqli_query($db, $command);
if ($result && mysqli_num_rows($result) > 0) {
while ($row = mysqli_fetch_assoc($result)) {
$myusername = $row[‘allusername’];
}
}
echo “The distinct count of usernames is “.$myusername.”<br/>”;
$command= “SELECT distinct username from tablename ORDER BY date asc “;
$result = mysqli_query($db, $command);
if ($result && mysqli_num_rows($result) > 0) {
$myusernames= mysqli_num_rows($result);
echo “The distinct count of usernames is “.$myusernames.”<br/>”;
}
© 2018 ALL Rights Reserved | Sitemap
Vancouver | North Vancouver | Burnaby | Richmond | Coquitlam | Port Coquitlam | Surrey | Langley | Maple Ridge | Mission | Abbotsford | Kamloops | Kelowna | Victoria | Squamish | Whistler | Pemberton