SSIS - SQL 没有输出的更新查询:错误

SSIS - SQL Update Query without output: Error

我正在尝试 运行 在 SSIS 包中间进行更新查询,并通过 SQL 执行此操作,而不是使用所有内置逻辑门,以避免头痛.我 运行 遇到的问题是,如果我 return 没有结果,它会给我一个错误:

Error 1 Validation error. No column information was returned by the SQL command.

本地我原来有:

SELECT 1 [placeholder] 

在我的查询结束时欺骗它执行,但是当我将这个包作为自动化作业导入到 SQL 服务器时,它跳过了这个更新,因为 SELECT 1 [placeholder]从未使用过,所以它认为它是 "unnecessary code":

Error: Update has been removed from the Data Flow task because its output is not used and its inputs either have no side effects or are not connected to outputs of other components. If the component is required, then the HasSideEffects property on at least one of its inputs should be set to true, or its output should be connected to something.

所以我转向我的 SSIS 包并去设置 HasSideEffects = True,但是它是灰色的并且不允许我更改它,所以现在我不确定是什么去做。如何在不使用内置逻辑门的情况下解决这个问题?任何帮助,将不胜感激。谢谢!

感谢 Brad 的帮助,意识到我需要使用 "Execute SQL Task" 而不是 "Data Flow Task"。