var sidebar_align = 'right';
var content_container_margin = parseInt('290px');
var sidebar_width = parseInt('270px');
Unanswered: SSIS Questions: Import files with filenames that change and/or empty files and/or bad
FIRST QUESTION: file names that change. How do I specify in the flat file source a file name that can change (that is parameter driven)?
I am importing 25 files using SSIS. The file names change as follows:
Yesterday's File: Claim_header.2455307
Today's file: Claim_header.2455308
Tomorrows file: Claim_header.2455309
The number is a Julian date. There is an activeX script task that calculates it and sets a parameter called gsJulianDate.
SECOND QUESTION: we get files that have no data. Normal. Is there a way to detect an empty file before trying to load it?
THIRD QUESTION: There are often bad dates. Stuff like 5/1/2210. Out of range for smallDateTime. Is there a simple way to handle these? A filter perhaps? Or some other trick?
Appreciate your time and help.
Is there any harm in trying to load an empty file?
If it is really a problem then I suggest you perform the check in your ActiveX script
As for the validation - once again, ActiveX should be your friend here.
Set fso = CreateObject("Scripting.FileSystemObject")
Set file = fso.GetFile("C:\yourfile.txt")
If fso.Size > 0 Then
' File isn't empty
' File IS empty