March 3, 2014 at 8:58 pm
Hi all,
We have an SSIS package that produces around 100 flat files in lieu of a proper integration broker.
This package runs weekly. About once a month, the package fails with the "cannot open the datafile....." for one of the files, this file differs each time.
Permissions are NOT an issue, as the package reads metadata and generates all other 99 files with no problem, and all use the same user for DB connection.
The package is set to overwrite the existing files and also make an archive .xls in a seperate dir. The problem is resolved when the file in question is deleted and the package re-run manually. How ever I am interested to know why it happens in the first place.
Any ideas on what could cause this would be very helpful.
Cheers.
March 4, 2014 at 1:42 am
I think overwrite or deleting existing file from source folder could be an issue. After loading data into staging table, you can move those file into Archive folder in place of overwrite existing file and moving to archive folder on same time.
March 4, 2014 at 3:02 am
Yes, thank you for the response, I could setup a file task that moves .csv to another folder or deleting them totally before running the job, I am however interested in why the SQL agent fails at reading the metadata from the file causing job failure in a random fashion. This points to a core SSIS issue that may need to be addressed by MS.
March 4, 2014 at 5:48 am
is it possible tha that the file being read is still being written by some other process , and you are accidentally grabbing it mid-stream? i know i had an FTP issue like that once before; file was still being written when i grabbed it.
Lowell
March 13, 2014 at 7:51 am
I'm with Lowell on this one. Something has gotten hold of the file you are trying to write to. You could try writing to a unique filename (add a timestamp using a variable...) and then a file system task to rename it. the rename would fail, but at least you would have output the data. If this still failed then I would suggest network dropouts or disk space might be an issue.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply