[問題類型]:
經驗諮詢(我想用R 連接某些資料庫,請問大家的經驗)
[軟體熟悉度]:
新手(沒寫過程式,R 是我的第一次)
[問題敘述]:
依據版大的建議想要使用Roracle的套件,但安裝失敗,環境變數都已經設定了
還是有錯誤訊息,想請叫大家該怎麼修改?
首先說明一下我相關的環境變數
PATH=
C:\oracle\product\12.1.0\client_1\bin;
c:\Rtools\bin;
c:\Rtools\mingw_32\bin;
C:\ProgramData\Oracle\Java\javapath;
C:\Program Files\R\R-3.3.3\bin
OCI_LIB64=C:\oracle\product\12.1.0\client_1\bin
OCI_INC=C:\oracle\product\12.1.0\client_1\sdk\include (oci.h在這目錄下)
[程式範例]:
install.packages("ROracle",type = "source")
錯誤訊息如下:
trying URL 'https://cran.rstudio.com/src/contrib/ROracle_1.3-1.tar.gz'
Content type 'application/x-gzip' length 308252 bytes (301 KB)
downloaded 301 KB
* installing *source* package 'ROracle' ...
** package 'ROracle' successfully unpacked and MD5 sums checked
ERROR: cannot find Oracle Client.
Please set OCI_LIB64 to specify its location.
Warning: 執行中命令 'sh ./configure.win' 已有狀態 1
ERROR: configuration failed for package 'ROracle'
* removing 'C:/Program Files/R/R-3.3.3/library/ROracle'
Warning in install.packages :
running command '"C:/PROGRA~1/R/R-3.3.3/bin/x64/R" CMD INSTALL -l
"C:\Program Files\R\R-3.3.3\library"
C:\Users\myID\AppData\Local\Temp\RtmpCYB3hn/downloaded_packages/ROracle_1.3-1.tar.gz'
had status 1
Warning in install.packages :
installation of package ‘ROracle’ had non-zero exit status
The downloaded source packages are in
‘C:\Users\myID\AppData\Local\Temp\RtmpCYB3hn\downloaded_packages’
[環境敘述]:
R version 3.3.3 (2017-03-06)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1
locale:
[1] LC_COLLATE=Chinese (Traditional)_Taiwan.950 LC_CTYPE=Chinese
(Traditional)_Taiwan.950
[3] LC_MONETARY=Chinese (Traditional)_Taiwan.950 LC_NUMERIC=C
[5] LC_TIME=Chinese (Traditional)_Taiwan.950
attached base packages:
[1] stats graphics grDevices utils datasets methods base
loaded via a namespace (and not attached):
[1] tools_3.3.3
[關鍵字]:
Roracle、windows7
麻煩高人解惑~不知道是哪個環節問題