createCursor.py

import pymssql
import logging

def createCursor(serverAddress, userName, password, dataBase):
# create connection and cursor
conn = pymssql.connect(serverAddress, userName, password, dataBase, charset = "UTF-8")
logging.info("sqlServer connection Successfully Created. ")
cursor = conn.cursor()
logging.info("cursor Successfully Created. ")
return conn, cursor
上一篇:Java总复习(二)——MySQL


下一篇:auto.js B0015 python sqlite 数据库创建