How to access databases from R

May 5, 2011

(This article was first published on Revolutions, and kindly contributed to R-bloggers)

From his presentation at the Greater Boston useR Group[*], R user Jeffrey Breen has shared some useful slides detailing how to bring data from relational databases like MySQL and Oracle. In fact, data from just about any relational database is accessible from R by sending an SQL query to the standard ODBC or JDBC interfaces. R packages also offer other handy tricks, like being able to loop R code over the elements of a SQL result set. Even if you aren't using a relational database, you can still perform SQL queries on R data directly. Check out Jeff's slides at the link below, especially slide 10 which includes links to many useful database-access resources for R.

Greater Boston useR Group: useR Vignette – Accessing Databases from R – 20110504 (Jeffrey Breen)

[*] Proudly sponsored by Revolution Analytics

To leave a comment for the author, please follow the link and comment on their blog: Revolutions. offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...

If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Tags: ,

Comments are closed.

Search R-bloggers


Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)