Retrieves information on objects of class DBIDriver, DBIConnection or DBIResult.
Arguments
- dbObj
An object inheriting from DBIObject, i.e. DBIDriver, DBIConnection, or a DBIResult
- ...
Other arguments to methods.
Value
For objects of class DBI::DBIDriver, dbGetInfo()
returns a named list
that contains at least the following components:
driver.version
: the package version of the DBI backend,client.version
: the version of the DBMS client library.
For objects of class DBI::DBIConnection, dbGetInfo()
returns a named list
that contains at least the following components:
db.version
: version of the database server,dbname
: database name,username
: username to connect to the database,host
: hostname of the database server,port
: port on the database server. It must not contain apassword
component. Components that are not applicable should be set toNA
.
For objects of class DBI::DBIResult, dbGetInfo()
returns a named list
that contains at least the following components:
statatment
: the statement used withDBI::dbSendQuery()
orDBI::dbExecute()
, as returned byDBI::dbGetStatement()
,row.count
: the number of rows fetched so far (for queries), as returned byDBI::dbGetRowCount()
,rows.affected
: the number of rows affected (for statements), as returned byDBI::dbGetRowsAffected()
has.completed
: a logical that indicates if the query or statement has completed, as returned byDBI::dbHasCompleted()
.
Implementation notes
The default implementation for DBIResult objects
constructs such a list from the return values of the corresponding methods,
dbGetStatement()
, dbGetRowCount()
,
dbGetRowsAffected()
, and dbHasCompleted()
.
See also
Other DBIDriver generics:
DBIDriver-class
,
dbCanConnect()
,
dbConnect()
,
dbDataType()
,
dbDriver()
,
dbIsReadOnly()
,
dbIsValid()
,
dbListConnections()
Other DBIConnection generics:
DBIConnection-class
,
dbAppendTable()
,
dbAppendTableArrow()
,
dbCreateTable()
,
dbCreateTableArrow()
,
dbDataType()
,
dbDisconnect()
,
dbExecute()
,
dbExistsTable()
,
dbGetException()
,
dbGetQuery()
,
dbGetQueryArrow()
,
dbIsReadOnly()
,
dbIsValid()
,
dbListFields()
,
dbListObjects()
,
dbListResults()
,
dbListTables()
,
dbQuoteIdentifier()
,
dbReadTable()
,
dbReadTableArrow()
,
dbRemoveTable()
,
dbSendQuery()
,
dbSendQueryArrow()
,
dbSendStatement()
,
dbUnquoteIdentifier()
,
dbWriteTable()
,
dbWriteTableArrow()
Other DBIResult generics:
DBIResult-class
,
dbBind()
,
dbClearResult()
,
dbColumnInfo()
,
dbFetch()
,
dbGetRowCount()
,
dbGetRowsAffected()
,
dbGetStatement()
,
dbHasCompleted()
,
dbIsReadOnly()
,
dbIsValid()
,
dbQuoteLiteral()
,
dbQuoteString()
Examples
dbGetInfo(RSQLite::SQLite())
#> $driver.version
#> [1] ‘2.3.7’
#>
#> $client.version
#> [1] ‘3.46.0’
#>