How to connect to MS SQL Server using Python3 on MacOS

MS SQL Server
MS SQL Server
Simply follow the steps below


  • Install pyodbc in python3
pip3 install pyodbc

or

python3 -m pip install pyodbc
  • Now install Microsoft ODBC Driver (need to have Homebrew installed on your system)
brew tap microsoft/msodbcsql https://github.com/Microsoft/homebrew-msodbcsql
  • Update homebrew
brew update
  • Final Step
brew install msodbcsql
  • Now take idea from following python3 code

Hope it helps.

Popular posts from this blog

RTU B.Tech 4th semester Computer science Syllabus (Common to IT also)

[How to] install Remastersys on Unbuntu 14.04 [Linux] with GUI support

[How to] Connect an android device [using MTP] on Linux [Ubuntu 14.04 LTS] 100% working