使用SSIS包中的Python脚本预测数据 [英] Predicting data with Python script in an SSIS package

查看:89
本文介绍了使用SSIS包中的Python脚本预测数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我知道Microsoft在其用于SQL Server的机器学习服务中包含Python,但这仅适用于SQL Server 2017及更高版本,这是我的服务器当前无法满足的要求.

I'm aware of Microsoft's inclusion of Python in their Machine Learning Services for SQL server, however this is only available for SQL Server 2017 and up, which is a requirement my servers do not currently meet.

在这种情况下,我想将带有训练模型的生成预测管道完全部署在SSIS中,即:

With that being the case, I wanted to deploy my generate-predictions-with-trained-model pipeline entirely within SSIS, I.E:

  1. 从我的数据库中获取数据
  2. 将其传递给Python脚本数据流任务,该任务将导入训练后的模型,生成预测并将其传递给下一个数据流任务
  3. 将预测结果写入数据库

是否有一种方法可以完全在SSIS中完成此操作,还是仅需要使用执行流程任务"启动Python脚本并将其分别存储在服务器的某个位置上?

Is there a way to do that entirely within SSIS, or will it be necessary to just use Execute Process Task to kick off the Python script and have that stored separately on the server somewhere?

欢呼

推荐答案

执行此操作的唯一方法是将脚本保存到文件中,并使用执行流程任务

The only way to do that is to save the the script into a file and execute it using an Execute Process Task .

您不能在SSIS包中编写python脚本.基于官方文档:

You cannot write python scripts within SSIS packages. Based on the official documentation :

脚本任务使用的Microsoft Visual Studio应用程序工具(VSTA)开发环境支持Visual Basic 2005和Visual C#编程语言.

The Microsoft Visual Studio Tools for Applications (VSTA) development environment used by the Script task supports the Visual Basic 2005 and Visual C# programming languages.

这篇关于使用SSIS包中的Python脚本预测数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆