# Class Result

Result object given by a `DataTables\Database\Query` performed on a database.

The typical pattern for using this class is to receive an instance of it as a result of using the Database and `DataTables\Database\Query` class methods that return a result. This class should not be initialised independently.

Note that this is a stub class that a driver will extend and complete as required for individual database types. Individual drivers could add additional methods, but this is discouraged to ensure that the API is the same for all database types.

Namespace: DataTables\Database
Located at Database/Result.php

Methods summary
`public integer` | # `count( )` Count the number of rows in the result set. Count the number of rows in the result set. #### Returns integer
`public array` | # `fetch( integer $fetchType = \PDO::FETCH_ASSOC )` Get the next row in a result set Get the next row in a result set #### Parameters $fetchType row fetch style - PDO::FETCH_ASSOC is the default #### Returns array
`public array` | # `fetchAll( integer $fetchType = \PDO::FETCH_ASSOC )` Get all rows in the result set Get all rows in the result set #### Parameters $fetchType row fetch style - PDO::FETCH_ASSOC is the default #### Returns array
`public integer` | # `insertId( )` After an INSERT query, get the ID that was inserted. After an INSERT query, get the ID that was inserted. #### Returns integer