Rdbi

News: R database development is now consolidating on a new interface 'DBI' written by David James. 'DBI' is based partly on 'Rdbi' (which was based partly on David's original proposal) and I will be port 'Rdbi.PgSQL' to 'DBI.PgSQL' when time allows. If that's not soon enough, drop me a note and I'll point you to the code. It should not take a large effort Visit the R database-access development home page for more information.

Rdbi is a general database access framework for the R statistical computing environment.  It is the successor to RPgSQL, a PostgreSQL specific package.  I have provided Rdbi binding for PostgreSQL.  If you would like to add bindings for your favorite database, please contact me (see Rdbi.PgSQL in CVS for example code).  If you already use RPgSQL, you will find the Rdbi bindings 10-100 times faster on reads as all result fetch loops have been moved into C code.

To download the R packages, visit CRAN .  Also, try typing "?update.packages" from the R prompt.

Example session:

conn <- dbConnect(PgSQL(), host = "myhost", dbname = "mydb")
res <- dbSendQuery(conn, "select * from mytable")
mydata <- dbGetResult(res)

Sourceforge project page

SourceForge Logo