Function Database_super_mysql->get_table_count_approx
Definitions
sources/database/shared/mysql.php
- Get the number of rows in a table, with approximation support for performance (if necessary on the particular database backend).
- Visibility: public
- Is abstract?: No
- Is static?: No
- Is final?: No
- Returns: int
Parameters
Name | Type | Passed by reference? | Variadic? | Default | Set | Range | Description |
---|---|---|---|---|---|---|---|
$table | string | No | No | required parameter | N/A | N/A | The table name |
$connection | mixed | No | No | required parameter | N/A | N/A | The DB connection |
Returns
- The count (null: do it normally)
- Type: ?integer
- Set: N/A
- Range: N/A
Preview
Code (PHP)
/**
* Get the number of rows in a table, with approximation support for performance (if necessary on the particular database backend).
*
* @param string $table The table name
* @param mixed $connection The DB connection
* @return ?integer The count (null: do it normally)
*/
public function get_table_count_approx(string $table, $connection) : ?int
* Get the number of rows in a table, with approximation support for performance (if necessary on the particular database backend).
*
* @param string $table The table name
* @param mixed $connection The DB connection
* @return ?integer The count (null: do it normally)
*/
public function get_table_count_approx(string $table, $connection) : ?int