|
MS SQL и модуль Python
|
|||
---|---|---|---|
#18+
Добрый день. Помогите разобраться с ошибкой. Есть 2017 сервер. На него установлен компонент Python. При выполнении кода через cmd все отрабатывает. c:\Program Files\Microsoft SQL Server\MSSQL14.SQL1C\PYTHON_SERVICES>python.exe Python 3.5.2 |Continuum Analytics, Inc.| (default, Jul 5 2016, 11:41:13) [MSC v.1900 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. >>> test='Привет' >>> print(test) Привет >>> При выполнении скрипта через SSMS: EXECUTE sp_execute_external_script @language = N'Python', @script = N' test="Привет" print(test) ' Получаю ошибку: Msg 39004, Level 16, State 20, Line 0 A 'Python' script error occurred during execution of 'sp_execute_external_script' with HRESULT 0x80004004. Msg 39019, Level 16, State 2, Line 0 An external script error occurred: Error in execution. Check the output for more information. Traceback (most recent call last): File "<string>", line 3, in <module> File "C:\PROGRA~1\MICROS~1\MSSQL1~1.SQL\MSSQL\EXTENS~1\SQL1C01\DEE523C7-090F-4921-93B2-566922F94914\sqlindb.py", line 29 test="Привет" ^ IndentationError: unexpected indent SqlSatelliteCall error: Error in execution. Check the output for more information. STDOUT message(s) from external script: Express Edition will continue to be enforced. SqlSatelliteCall function failed. Please see the console output for more information. Traceback (most recent call last): File "C:\Program Files\Microsoft SQL Server\MSSQL14.SQL1C\PYTHON_SERVICES\lib\site-packages\revoscalepy\computecontext\RxInSqlServer.py", line 406, in rx_sql_satellite_call rx_native_call("SqlSatelliteCall", params) File "C:\Program Files\Microsoft SQL Server\MSSQL14.SQL1C\PYTHON_SERVICES\lib\site-packages\revoscalepy\RxSerializable.py", line 291, in rx_native_call ret = px_call(functionname, params) RuntimeError: revoscalepy function failed. Использование внешних скриптов на MS SQL включено ... |
|||
:
Нравится:
Не нравится:
|
|||
31.08.2020, 13:27 |
|
|
start [/forum/topic.php?fid=46&fpage=50&tid=1685717]: |
0ms |
get settings: |
11ms |
get forum list: |
13ms |
check forum access: |
3ms |
check topic access: |
3ms |
track hit: |
32ms |
get topic data: |
9ms |
get forum data: |
2ms |
get page messages: |
24ms |
get tp. blocked users: |
2ms |
others: | 16ms |
total: | 115ms |
0 / 0 |