I use pymssql to connect the sql server database with macOS,
import pandas as pd
import numpy as np
from sqlalchemy import create_engine
import pymssql
conn = pymssql.connect(host='', port=1433, user='', password='', database='', charset='gbk')
if I set charset with 'utf8', it come out with error connection failed, if I set charset with 'gbk', it come out with error as below:
18456, b'DB-Lib error message 20010, severity 8:\nUnable to allocate sufficient memory
Where I use navicat to connect this sql server database work well.