CI_DB_driver::db_pconnect()

db_pconnect() Returns: Database connection resource/object or FALSE on failure Return type: mixed Establish a persistent connection with the database. Note This method is just an alias for db_connect(TRUE).

CI_DB_driver::db_set_charset()

db_set_charset($charset) Parameters: $charset (string) – Character set name Returns: TRUE on success, FALSE on failure Return type: bool Set client character set.

CI_DB_driver::db_select()

db_select([$database = '']) Parameters: $database (string) – Database name Returns: TRUE on success, FALSE on failure Return type: bool Select / switch the current database.

CI_DB_driver::elapsed_time()

elapsed_time([$decimals = 6]) Parameters: $decimals (int) – The number of decimal places Returns: The aggregate query elapsed time, in microseconds Return type: string Calculate the aggregate query elapsed time.

CI_DB_driver::db_connect()

db_connect($persistent = TRUE) Parameters: $persistent (bool) – Whether to establish a persistent connection or a regular one Returns: Database connection resource/object or FALSE on failure Return type: mixed Establish a connection with the database. Note The returned value depends on the underlying driver in use. For example, a mysqli instance will be returned with the ‘mysqli’ driver.

CI_DB_driver::cache_set_path()

cache_set_path([$path = '']) Parameters: $path (string) – Path to the cache directory Return type: void Sets the directory path to use for caching storage.

CI_DB_driver::count_all()

count_all([$table = '']) Parameters: $table (string) – Table name Returns: Row count for the specified table Return type: int Returns the total number of rows in a table, or 0 if no table was provided.

CI_DB_driver::call_function()

call_function($function) Parameters: $function (string) – Function name Returns: The function result Return type: string Runs a native PHP function , using a platform agnostic wrapper.

CI_DB_driver::compile_binds()

compile_binds($sql, $binds) Parameters: $sql (string) – The SQL statement $binds (array) – An array of binding data Returns: The updated SQL statement Return type: string Compiles an SQL query with the bind values passed for it.

CI_DB_driver::close()

close() Return type: void Close the DB Connection.