pythonpymssql

Python / Import module pymssql / from Linux to Windows


I have a python script running on linux, with this declaration :

import _mssql

In the library listed there is pymssql (I can't find other relative library)

I am trying to adapt this code to windows, so I have installed pymssql but when I try to declare it like in the linux version, I have this message :

ModuleNotFoundError: No module named '_mssql'

What could be the cause ? Why using an underscore to import this library ?


Solution

  • Yes obviously the correct syntax is :

    import pymssql._mssql