Answers for "how to run pyodbc"

SQL
3

connect with pyodbc with statement

with pyodbc.connect(conx_string) as conx:
    cursor = conx.cursor()
    cursor.execute(query)
    data = cursor.fetchall()
Posted by: Guest on April-21-2021
0

using pypyodbc

conn = pypyodbc.connect("DRIVER={SQL Server};SERVER=MyServer;UID=me;PWD=password;DATABASE=db")
Posted by: Guest on October-23-2021

Code answers related to "SQL"

Browse Popular Code Answers by Language