Skip to contents

Connect to a Virtuoso Server over ODBC

Usage

vos_connect(
  driver = NULL,
  uid = "dba",
  pwd = "dba",
  host = "localhost",
  port = "1111",
  system_odbcinst = find_odbcinst(),
  local_odbcinst = odbcinst_path()
)

Arguments

driver

Name of the Driver line in the ODBC configuration

uid

User id. Defaults to "dba"

pwd

Password. Defaults to "dba"

host

IP address of the Virtuoso Server

port

Port used by Virtuoso. Defaults to the Virtuoso standard port, 1111

system_odbcinst

Path to the system odbcinst.ini file. (Does not require write access.) Default will attempt to find the file for your system.

local_odbcinst

Path to the local odbcinst we should use.

Value

a DBI connection to the Virtuoso database. This can be passed to additional virtuoso functions such as vos_import()or vos_query(), and can also be used as a standard DBI or dplyr database backend.

Details

Default parameters are appropriate for the automatic installer provided by the package and for the default settings typically used by local Virtuoso installers. Adjust these only if you are connecting to a remote virtuoso server that is not controlled from the R package.

Examples

status <- vos_status()
#> virtuoso isn't running.
# \donttest{
if(has_virtuoso()){
## start up
vos_start()
con <- vos_connect()
}
#> PROCESS 'virtuoso-t', running, pid 1798.
#> Server is now starting up, this may take a few seconds...
#> latest log entry: 04:51:49 Server online at 1111 (pid 1798)
# }