Re: [R] Using ODBC/RODBC with DBI

From: Dirk Eddelbuettel <>
Date: Mon, 30 Jun 2008 08:23:00 -0500

On 30 June 2008 at 08:57, Magnus Torfason wrote:
| Hi all, I would like the following code to work, but it doesn't:
| library(DBI)
| library(RODBC)
| m <- dbDriver("RODBC") # Example for dbConnect(DBI), causes error
| m <- dbDriver("ODBC") # Example for DBIDriver-class(DBI), causes error
| The errors are:
| Error in, list(...)) :
| could not find function "RODBC"
| (substitute "ODBC" for "RODBC" to get the second error)
| I've successfully used RODBC without using the DBI interface, and I've
| successfully used the DBI interface with SQLite.
| Am I doing something wrong here or is DBI simply not implemented for ODBC?

Yes and yes ;-) If you use DBI, you need to use one of the supported backends.

As of right now, those are MySQL, SQLite, Oracle. I am mentoring a student in the 'Google Summer of Code' project going right who is adding PostgreSQL to the list; this is progressing well.

Nobody has 'connected' DBI and ODBC.

By the way, there is a mailing list r-sig-db for database discussions related to R.


Three out of two people have difficulties with fractions.

______________________________________________ mailing list
PLEASE do read the posting guide
and provide commented, minimal, self-contained, reproducible code.
Received on Mon 30 Jun 2008 - 14:04:52 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Mon 30 Jun 2008 - 14:30:49 GMT.

Mailing list information is available at Please read the posting guide before posting to the list.

list of date sections of archive