1

When I was using R 3.4.0 (64bit), the following code worked perfectly well.

#R Connect to Oracle DB
library(RODBC)
#Open connection
con <- odbcConnect(dsn = "DBNAME", uid="myuserid", pwd="mypassword",rows_at_time=500)

However I recently updated to R 3.5.2 (64bit), and now I cannot connect anymore.

I get the following error message when I try

Warning messages: 1: In RODBC::odbcDriverConnect("DSN=DBNAME;UID=myuserid;PWD=mypassword", : [RODBC] ERROR: state IM002, code 0, message [Microsoft][Gestionnaire de pilotes ODBC] Source de données introuvable et nom de pilote non spécifié 2: In RODBC::odbcDriverConnect("DSN=DBNAME;UID=myuserid;PWD=mypassword", : ODBC connection failed

Any help on resolving this issue will be highly appreciated.

Varun
  • 1,211
  • 1
  • 14
  • 31
  • Try updating package: `install.packages("RODBC")`. – Parfait Feb 22 '19 at 11:58
  • Tried that. No luck – Varun Feb 22 '19 at 13:07
  • Did anything else happen with R update such as an OS upgrade (Win 7 to Win 10)? Did you move over DSN file to new or rebuilt machine? – Parfait Feb 22 '19 at 21:10
  • No. Funny thing is when I switch projects in RStudio and run the same code it works. – Varun Feb 23 '19 at 13:52
  • What happens if you use a connection string instead? See: https://stackoverflow.com/a/28941648 - And: Are you sure the DSN name is correct and works (try it in the ODBC Manager)? – R Yoda Mar 06 '19 at 14:59

0 Answers0