Addition conditions in Data Flow Task
i am working on ssis package which has data flow task. The data flow task starts with script component which does some processiing and sets a flag which will decide if the flow should continue or not. At the end of the data flow task is the flat file destination to be created. Now i want to check if the flag = 'false' then don't create the flat file else create it. I tried using conditional split in data flow but it didn't worked. Instead the flat file destination task keeps excuting . Please suggest.
October 14th, 2011 12:36pm

How are you setting the flag? I would create a variable, and then set it inside that script component. Your condition split can then acces the same variable and make its decision to flow data to the file or not.Tom SQL Server MVP Toronto, ON Canada
Free Windows Admin Tool Kit Click here and download it now
October 14th, 2011 12:42pm

I dont think you can do this this is the Default Behavior of Data Flow Task see this thread http://social.msdn.microsoft.com/Forums/en-US/sqlintegrationservices/thread/e570b7fe-ef27-4b56-9f1f-a72a464f8705 Workaround: Place a rowcount before flat file detination and in Control Flow create a File System Task to delete the file if record count is 0.Shailesh, Please mark the post as answered if it answers your question.
October 14th, 2011 12:42pm

Why dont you try putting the value in variable and check it accordingly ??? Configure precedence constraint accordingly you should get it... done. Mark as answer if the post help you... Regards, Indraneel A
Free Windows Admin Tool Kit Click here and download it now
October 14th, 2011 12:49pm

@Tom : yes, i did the same. I set the variable in script component and used condition split.
October 14th, 2011 1:16pm

I dont think you can do this this is the Default Behavior of Data Flow Task see this thread http://social.msdn.microsoft.com/Forums/en-US/sqlintegrationservices/thread/e570b7fe-ef27-4b56-9f1f-a72a464f8705 Workaround: Place a rowcount before flat file detination and in Control Flow create a File System Task to delete the file if record count is 0.Shailesh, Please mark the post as answered if it answers your question.
Free Windows Admin Tool Kit Click here and download it now
October 14th, 2011 7:29pm

I dont think you can do this this is the Default Behavior of Data Flow Task see this thread http://social.msdn.microsoft.com/Forums/en-US/sqlintegrationservices/thread/e570b7fe-ef27-4b56-9f1f-a72a464f8705 Workaround: Place a rowcount before flat file detination and in Control Flow create a File System Task to delete the file if record count is 0.Shailesh, Please mark the post as answered if it answers your question.
October 14th, 2011 7:29pm

Thanks friends, as suggested by you people, i used a variable which will set the flag in script component of data flow task and configured precedence constraint in control flow before file system task and delete the file accordingly.
Free Windows Admin Tool Kit Click here and download it now
October 17th, 2011 7:06am

Thanks friends, as suggested by you people, i used a variable which will set the flag in script component of data flow task and configured precedence constraint in control flow before file system task and delete the file accordingly.
October 17th, 2011 7:06am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics