헤르메스 LIFE

[Python] _mssql.MSSQLDatabaseException: (20010, b'DB-Lib error message 20010, severity 8 본문

Exception

[Python] _mssql.MSSQLDatabaseException: (20010, b'DB-Lib error message 20010, severity 8

헤르메스의날개 2021. 3. 3. 01:34
728x90

환경 : Python

pymssql 을 이용한 MSSQL Database Connection Test 시 아래와 같은 오류가 발생했습니다.


Traceback (most recent call last):
File "src\pymssql.pyx", line 636, in pymssql.connect
File "src\_mssql.pyx", line 1964, in _mssql.connect
File "src\_mssql.pyx", line 682, in _mssql.MSSQLConnection.__init__
File "src\_mssql.pyx", line 1690, in _mssql.maybe_raise_MSSQLDatabaseException
_mssql.MSSQLDatabaseException: (20010, b'DB-Lib error message 20010, severity 8:\nUnable to allocate sufficient memory (localhost)\nOperating System error during No error (12)\n')


self.conn = pymssql.connect(
host=self.host,
user=self.user,
password=self.passwd,
port=self.port,
database=self.db,
charset='utf-8'
)


'utf-8' 을 'utf8' 로 변경하니 오류가 사라졌습니다.

728x90