Skip to content

Tag: pyodbc

Inser list of ids into table aioodbc (pyodbc)

I am using aioodbc which is basically async pyodbc. My table has only one columns ClaimID. I am trying to do bukl insert list of ids like [1, 2, ,3 ,4 ,5 ,6 … n] (up to 21k) where ids is a python list of ints. I am getting error How to perform bulk insert of list of ids ?

Test Connection pyodbc (Python and SSMS)

I’m trying to follow some simple steps in this Microsoft doco but I can get it to connect. What am I doing wrong? This is the error message: PS C:UsersNelson.Silva> & Answer You changed your code before posting. In the code block you say the connect line is but in the exception block the line is:…

pyodbc legacy-install-failure in ubuntu python 3.9

I am not being able to install pyodbc Sorry for the image, but it is on a private network and it does not allow me to do a copy-paste I saw solutions like this, but it is for windows. I can’t downgrade my python 3.9 either. Do you know a solution for this pyodbc installing? Answer Had the same issue

Does not detach database by sp_detach_db in pyodbc

I am trying to detach the database, but for some reason it does not detach with no error, am I missing something? SQLServer 2012 version: 11.0.2100 pyodbc version: 4.0.31 Answer Thx for Gord Thompson for the tip. Fixes: SET SINGLE_USER WITH NO_WAIT -> SET TRUSTWORTHY ON Remove from connect params “Tr…