Trying to install the dbt-sqlserver
package via pip (Python 3.11) results in an error related to pyodbc
.
The error is: “Microsoft Visual C++ 14.0 or greater is required.”
Microsoft Visual C++ is installed on the local machine, and in the right version.
Installing pyodbc on its own goes just fine. However, the version of pyodbc
that dbt-sqlserver
is trying to install is 4.0.32 whereas the most recent version currently available is 4.0.35.
I asked pyodbc maintainers for help and they said that version 4.0.32 didn’t have wheels for Python 3.11: Windows 11. Python 3.10.1 Impossible to install pyodbc · Issue #1010 · mkleehammer/pyodbc · GitHub
I am just starting my Python adventure and I don’t really understand what is going on here. Pyodbc maintainers are suggesting reaching out to dbt-sqlserver authors and clarify with them why they are including an older version of pyodbc library in their product.
This is the exact error message I am getting:
running build
running build_ext
building 'pyodbc' extension
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-build-tools/
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
Rolling back uninstall of pyodbc
Moving to c:\program files\python311\lib\site-packages\pyodbc-4.0.35.dist-info\
from C:\Program Files\Python311\Lib\site-packages\~yodbc-4.0.35.dist-info
Moving to c:\program files\python311\lib\site-packages\pyodbc.cp311-win_amd64.pyd
It is a Windows 11 PC with Python 3.11.0
Any hints welcome.