Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can't connect to MS Access with odbc 1.2.0 #325

Closed
xzhang16 opened this issue Dec 5, 2019 · 6 comments
Closed

Can't connect to MS Access with odbc 1.2.0 #325

xzhang16 opened this issue Dec 5, 2019 · 6 comments

Comments

@xzhang16
Copy link

xzhang16 commented Dec 5, 2019

After updating to odbc 1.2.0, I get error when setting up connection to MS Access 2016. So I have to reinstall the older version to get things done.

The following code works well with odbc 1.1.6

library(odbc)
con <-
      dbConnect(
        drv = odbc(),
        .connection_string = "Driver={Microsoft Access Driver (*.mdb, *.accdb)}; DBQ=mypath/datafile.mdb;"
      )

I get this error with odbc 1.2.0

Error in connection_info(ptr) : nanodbc/nanodbc.cpp:1072: Æe¹,Í:
@leonh-dev
Copy link

I have exactly the same issue! As a workaround, I switched to RODBC.

@vh-d
Copy link
Contributor

vh-d commented Dec 8, 2019

I can confirm the issue.

It looks like it was introduced by 947b8d5, as f5f1c03 is the last working version.

@jimhester
Copy link
Contributor

jimhester commented Dec 9, 2019

Thanks for tracking it down @vh-d, it should now be fixed, let me know if that is not the case.

@StewartRossInv01
Copy link

I too have experienced this problem, with version 1.2.0 (installed recently) and now 1.2.1 (installed after reading the comment from @jimhester above.).

channel = dbConnect(drv = odbc::odbc(), .connection_string = cstring)
Error in connection_info(ptr) : nanodbc/nanodbc.cpp:1072: �j¸`­:

Version 1.1.6 connects perfectly.

Issue is currently closed, but does not appear to have been cured I'm sorry to say.

@divinenephron
Copy link

The fix wasn't present in version 1.2.1. Until the next release you can install the latest development version to get the fix:

devtools::install_github("r-dbi/odbc")

@kkirstein
Copy link

I can confirm that this issue also occurs when accessing MS Access 2010 databases. Upgrading to the dev version fixes it, as stated above.
Great work!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants