App\services\Database::getRecordNum PHP Method

getRecordNum() public method

public getRecordNum ( $table = null )
    public function getRecordNum($table = null)
    {
        $table = $table ?: $this->tableName;
        $sql = "SELECT * FROM {$table} WHERE 1";
        return $this->query($sql)->num_rows;
    }