Firefox PHP

How to get unique numbers of authors through all forums

Posted by Phil 
Hi,

In the stats, you can have the unique number of author per forum, but not for the whole forums.

I did some code that is working fine, but that simply add the number of different authors per forum, but not really the number of unique authors.
Any idea on how to do it ?

Thanks

$sql="Select distinct(table_name) from ".$pho_main." where folder='0'";
$q=new query($DB, $sql);
$forums=$q->getrow();

$totalauthors=0;
while(is_array($forums)){
//Count authors in each forum
$sql="SELECT DISTINCT author,email FROM $forums[table_name] WHERE datestamp >='$date_range'";
$query=new query($DB, $sql);
$authors=$query->numrows();
//Add Them To totals
$totalauthors=$totalauthors+$authors;
$forums=$q->getrow();
}
Re: How to get unique numbers of authors through all forums
September 26, 2004 09:45PM
you'd have to make them unique through all the forums.
all you do is summing up the unique authors you got for each forum.

Sorry, you do not have permission to post/reply in this forum.