dbWriteTable,ODBCConnection,character,data.frame-method {RODBCDBI} | R Documentation |
Write a local data frame or file to the database.
Description
Write a local data frame or file to the database.
Usage
## S4 method for signature 'ODBCConnection,character,data.frame'
dbWriteTable(conn, name, value,
overwrite = FALSE, append = FALSE, ...)
Arguments
conn |
a |
name |
a character string specifying a table name. ODBCConnection table names
are not case sensitive, e.g., table names |
value |
a data.frame (or coercible to data.frame) object or a
file name (character). when |
overwrite |
logical. Should data be overwritten? |
append |
logical. Should data be appended to an existing table? |
... |
additional arguments passed to the generic. |
Examples
## Not run:
library(DBI)
con <- dbConnect(RODBCDBI::ODBC(), dsn="test", user="sa", password="Password12!")
dbWriteTable(con, "mtcars", mtcars, overwrite=TRUE)
dbReadTable(con, "mtcars")
dbDisconnect(con)
## End(Not run)
[Package RODBCDBI version 0.1.1 Index]