从 SQL Server Management Studio 导出数据库脚本文件,在 linux 上通过 mssql-cli 命令导入
mssql-cli -i blog.sql
命令执行时报错
Traceback (most recent call last):
File "/mssql-cli/lib/python3.6/runpy.py", line 193, in _run_module_as_main
"__main__", mod_spec)
File "/mssql-cli/lib/python3.6/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/mssql-cli/lib/python3.6/site-packages/mssqlcli/main.py", line 122, in
main()
File "/mssql-cli/lib/python3.6/site-packages/mssqlcli/main.py", line 115, in main
run_cli_with(mssqlcli_options)
File "/mssql-cli/lib/python3.6/site-packages/mssqlcli/main.py", line 67, in run_cli_with
text = f.read()
File "/mssql-cli/lib/python3.6/codecs.py", line 321, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0xff in position 0: invalid start byte
请问如何解决?