python連接Oracle報錯DPI-1047

Python 連接Oracle時提示::DatabaseError: DPI-1047: Cannot locate a 64-bit Oracle Client library: "The specified module could not be found". See https://oracle.github.io/odpi/doc/installation.html#windows for help
0
根據錯誤提示進入https://oracle.github.io/odpi/doc/installation.html#windows,下載對應的 instant client 包,然後解壓配置環境變量,再次運行,一般情況下可以運行成功,解決該問題。
 
如果還是提示 DPI-104 錯誤,則需要檢查 VC++ 是否安裝。檢查方法是運行下載的 instant client 目錄下的 genezi.exe 程序。例如:C:\oracle\instantclient_21_3\genezi.exe,如果執行時出錯則說明 vc_redist 沒有正確安裝。重新進入https://oracle.github.io/odpi/doc/installation.html#windows 頁面,根據對應的 Oracle 版本下載對應的 vc_redist.exe 版本。
0
下載後安裝即可解決問題。
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章