简体   繁体   English

SSIS包不会保存SQL命令

[英]SSIS package won't save SQL command

I am updating an SSIS package and modifying the SQL command of a lookup transformation, but have found that the command won't save. 我正在更新SSIS包并修改查找转换的SQL命令,但发现该命令将无法保存。 I will update the command, close the editor, save the package, close and re-open Visual Studio (Professional 2015), but my changes are not preserved. 我将更新命令,关闭编辑器,保存程序包,关闭并重新打开Visual Studio(Professional 2015),但不会保留我的更改。 There is a config file (.dtsConfig) for the package in which I have made the changes as well, but still no dice. 我在其中进行了更改的程序包中有一个配置文件(.dtsConfig),但仍然没有骰子。 Changes to the project, such as variables and connection managers and their use within the package (save for the SQL command) are, however, maintained. 但是,将保留对项目的更改,例如变量和连接管理器及其在程序包中的使用(保存为SQL命令)。

What reasons might there be for why this package won't let me save updated SQL commands? 为什么该软件包不允许我保存更新的SQL命令的原因是什么?

我仍然不确定为什么会发生这种情况,但是在高级编辑器中打开查找并修改SqlCommand和SqlCommandParam字段可以保留我的更改。

In addition to saving the package, be certain to also run a build. 除了保存程序包之外,一定还要运行构建。 This recreates the .dtsx package file with the new changes. 这将使用新更改重新创建.dtsx软件包文件。 Your question did not mention having done this very important step. 您的问题没有提到已经完成了这一非常重要的步骤。

That isn't answering the question, but provides you a guideline on how to troubleshoot the problem: 那不是回答问题,而是为您提供有关如何解决问题的指南:

After the change do a right click on a package and view a code in XML. 更改后,右键单击一个包,然后查看XML代码。 Look for your "SQL statement" is it there? 寻找您的“ SQL语句”吗?

Copy/paste XML into separate file, save and close the solution. 将XML复制/粘贴到单独的文件中,保存并关闭解决方案。 Reopen it and see if code has changed. 重新打开它,看看代码是否已更改。 Compare the changes. 比较更改。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM