|
cvs: pearweb /public_html package-stats.php: msg#00050php.pear.core
cellog Wed Oct 18 13:37:28 2006 UTC Modified files: /pearweb/public_html package-stats.php Log: limit downloads count to pear packages http://cvs.php.net/viewvc.cgi/pearweb/public_html/package-stats.php?r1=1.75&r2=1.76&diff_format=u Index: pearweb/public_html/package-stats.php diff -u pearweb/public_html/package-stats.php:1.75 pearweb/public_html/package-stats.php:1.76 --- pearweb/public_html/package-stats.php:1.75 Wed Oct 18 13:32:15 2006 +++ pearweb/public_html/package-stats.php Wed Oct 18 13:37:28 2006 @@ -16,7 +16,7 @@ | Authors: Martin Jansen <mj@xxxxxxx> | | Richard Heyes <richard@xxxxxxx> | +----------------------------------------------------------------------+ - $Id: package-stats.php,v 1.75 2006/10/18 13:32:15 cellog Exp $ + $Id: package-stats.php,v 1.76 2006/10/18 13:37:28 cellog Exp $ */ require_once 'HTML/Form.php'; @@ -335,7 +335,8 @@ $total_releases = number_format($dbh->getOne('SELECT COUNT(*) FROM releases r, packages p WHERE r.package = p.id AND p.package_type="pear"'), 0, '.', ','); $total_categories = number_format($dbh->getOne('SELECT COUNT(*) FROM categories'), 0, '.', ','); - $total_downloads = number_format($dbh->getOne('SELECT SUM(dl_number) FROM package_stats'), 0, '.', ','); + $total_downloads = number_format($dbh->getOne('SELECT SUM(dl_number) FROM package_stats, packages p + WHERE package_stats.pid = p.id AND p.package_type="pear"'), 0, '.', ','); $query = "SELECT sum(ps.dl_number) as dl_number, ps.package, ps.pid, ps.rid, ps.cid FROM package_stats ps, packages p WHERE p.id = ps.pid AND p.package_type = 'pear' -- PEAR CVS Mailing List (http://pear.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | cvs: pearweb /public_html package-stats.php: 00050, Greg Beaver |
|---|---|
| Next by Date: | cvs: pearweb / package.php package.xml /include pear-database.php /public_html index.php package-info.php /sql downloads.sql pearweb_mdb2schema.xml: 00050, Greg Beaver |
| Previous by Thread: | cvs: pearweb /public_html package-stats.phpi: 00050, Greg Beaver |
| Next by Thread: | cvs: pearweb /public_html package-stats.php: 00050, Greg Beaver |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |