Description Usage Arguments Examples
These methods are straight-forward implementations of the corresponding generic functions.
1 2 3 | ## S4 method for signature 'ODBCDriver'
dbConnect(drv, dsn, user = NULL, password = NULL,
connection, ...)
|
drv |
an object of class ODBCDriver |
dsn |
Data source name you defined by ODBC data source administrator tool. |
user |
User name to connect as. |
password |
Password to be used if the DSN demands password authentication. |
connection |
Connection string to use to connect to the ODBC database server (as per |
... |
Other parameters passed on to methods |
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
# Connect to a ODBC data source
con <- dbConnect(RODBCDBI::ODBC(), dsn="test")
# or using a connection string
con <- dbConnect(RODBCDBI::ODBC(),
connection="driver={SQL Server};server=mysqlhost;
database=mydbname;trusted_connection=true")
# Always cleanup by disconnecting the database
#' dbDisconnect(con)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.