1
0
mirror of https://github.com/e107inc/e107.git synced 2025-03-14 01:19:44 +01:00

Fixed a bad performance issue which involved a query that instead of getting a row count was getting an entire result set (a large percentage of the size of the forum_t table).

This commit is contained in:
streaky 2007-04-05 01:54:17 +00:00
parent ec2941c2ee
commit 47d22181eb

View File

@ -11,9 +11,9 @@
| GNU General Public License (http://gnu.org).
|
| $Source: /cvs_backup/e107_0.8/top.php,v $
| $Revision: 1.1.1.1 $
| $Date: 2006-12-02 04:33:10 $
| $Author: mcfly_e107 $
| $Revision: 1.2 $
| $Date: 2007-04-05 01:54:17 $
| $Author: streaky $
+----------------------------------------------------------------------------+
*/
require_once("class2.php");
@ -110,7 +110,7 @@ if ($action == "active") {
$ns->tablerender(LAN_7, $text, "nfp");
require_once(e_HANDLER."np_class.php");
$ftotal = $sql->db_Select("forum_t", "*", "thread_parent='0'");
$ftotal = $sql->db_Count("forum_t", "(*)", "WHERE thread_parent = 0");
$ix = new nextprev("top.php", $from, $view, $ftotal, "", "active.forum.".$view."");
}
}