dbSendStatement,DatabaseConnectorConnection,character-method | R Documentation |
The dbSendStatement()
method only submits and synchronously executes the
SQL data manipulation statement (e.g., UPDATE
, DELETE
,
INSERT INTO
, DROP TABLE
, ...) to the database engine. To query
the number of affected rows, call dbGetRowsAffected()
on the
returned result object. You must also call dbClearResult()
after
that. For interactive use, you should almost always prefer
dbExecute()
.
## S4 method for signature 'DatabaseConnectorConnection,character'
dbSendStatement(conn, statement, translate = TRUE, ...)
conn |
A DBIConnection object, as returned by
|
statement |
a character string containing SQL. |
translate |
Translate the query using SqlRender? |
... |
Other parameters passed on to methods. |
dbSendStatement()
comes with a default implementation that simply
forwards to dbSendQuery()
, to support backends that only
implement the latter.
dbSendStatement()
returns
an S4 object that inherits from DBIResult.
The result set can be used with dbGetRowsAffected()
to
determine the number of rows affected by the query.
Once you have finished using a result, make sure to clear it
with dbClearResult()
.
For queries: dbSendQuery()
and dbGetQuery()
.
Other DBIConnection generics:
DBIConnection-class
,
dbAppendTable()
,
dbCreateTable()
,
dbDataType()
,
dbDisconnect()
,
dbExecute()
,
dbExistsTable()
,
dbGetException()
,
dbGetInfo()
,
dbGetQuery()
,
dbIsReadOnly()
,
dbIsValid()
,
dbListFields()
,
dbListObjects()
,
dbListResults()
,
dbListTables()
,
dbReadTable()
,
dbRemoveTable()
,
dbSendQuery()
,
dbWriteTable()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.