Вопрос

I am trying to use Osisoft's PI ODBC client. I am on a 64 bit Windows 7 machine. Because of some issues with 32 to 64 bit connecions, Osisoft came up with this workaround. After following the directions I was able to see the PI-ODBC driver in the ODBC Data Source Administrator and I was able to configure it. The problem is that when I open R and use the package RODBC I get an error. This is the code I used and the error it generated:

> library("RODBC", lib.loc="C:/Program Files/R/R-2.15.3/library")

ch <- odbcConnect("PIWHI")

Warning messages:
1: In odbcDriverConnect("DSN=PIWHI") :
  [RODBC] ERROR: state IM014, code 0, message [Microsoft][ODBC Driver Manager] The specified DSN contains an architecture mismatch between the Driver and Application
2: In odbcDriverConnect("DSN=PIWHI") : ODBC connection failed

I'm lost as to why this is not working. I know everything with setting up the ODBC client worked...a rep from OSIsoft confirmed this. I'm not sure why R isn't able to connect to it

Это было полезно?

Решение

As it turns out the PI ODBC driver is a 32 bit driver. Because I was using a 64 bit version of R, a connection could not take place. I changed to a 32 bit version of R and it worked well.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top