From: Nicolas Boisselier Date: Wed, 8 Mar 2017 13:49:47 +0000 (+0000) Subject: lib/php/db/table.php X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=905b5cc44b9bc8d6ce8f55fa348ace8bbfb7bc89;p=nb.git lib/php/db/table.php --- diff --git a/lib/php/db/table.php b/lib/php/db/table.php index f5a49c1d..f49c6121 100644 --- a/lib/php/db/table.php +++ b/lib/php/db/table.php @@ -2110,6 +2110,7 @@ Class Table extends nb { $this->create_temporary(); $sql = $this->db()->method('tables'); + if (!self::p('count')) $sql .= " LIMIT 1"; $sql = "SELECT * FROM ($sql) t WHERE name=".$this->db()->quote($this->name); $sth = $this->db()->conn->query($sql,PDO::FETCH_ASSOC);