[R] Importing Access 2007 data with ROBC

Ryan Utz rutz at umces.edu
Wed Mar 10 02:00:32 CET 2010


Hi all,

I'm trying to import Microsoft Access data into R. It looks like I'm
supposed to use the ROBC package, and this works fine with old Access
files (those with an .mdb extension).

However, lovely Microsoft must constantly update their software. Modern
Access files have an .ACCDB extension. I cannot seem to coerce R to import
data from such a file. Any advice?

I've been using this code:

testdb <- file.path("c:/Salmon_data.mdb")
channel <- odbcConnectAccess(testdb)
Data <- sqlFetch(channel,"Table1")

When I replace it with an Access 2007 file:

testdb <- file.path("c:/Salmon_data.accdb")
channel <- odbcConnectAccess(testdb)
Data <- sqlFetch(channel,"Table1")

it does not work.

Thanks for any help!
Ryan Utz



More information about the R-help mailing list