script task下面用SSIS写的C#代码,可以Dts.TaskResult = (int)ScriptResults.Success;省略吗?因为无论它是可达还是被注释掉,任务仍然会成功执行。它是默认的Success吗?这看起来是一个无聊的问题,只是好奇:)
public void Main()
{
// TODO: Add your code here
int a = 0;
if (a == 1)
{
Dts.TaskResult = (int)ScriptResults.Success;
}
//or comment out "Dts.TaskResult = (int)ScriptResults.Success;" outside the "if" will still let the script run successfully
}