May 10, 2010 at 9:27 am
Hi,
I have a package that loads Excel files from a watched folder using a Data Flow task. The package expects the Excle file to be in a certain format. If not the package obviously fails. The load runs every 5 mins.
Once the package has failed once It keeps failing because it keeps finding an Excel file in the wrong format. To get round this I'm trying to put an on Error event to overwrite the corrupt file with a clean empty version of the sdame. My problem is that when the On Error fires the 'bad' excel file is still locked by the Data Flow task.
Any ideas?
Thanks
Allen
May 11, 2010 at 4:37 am
You could store the error in a variable. Store the results of your dataflow task in a temporary table.
Then, after the data flow task has finished, use a script task. This task will read the error variable and will then decide what to do: overwrite the file and discard the results, or write the results in the temporary table to a permanent table.
Need an answer? No, you need a question
My blog at https://sqlkover.com.
MCSE Business Intelligence - Microsoft Data Platform MVP
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply