December 4, 2008 at 12:43 pm
I have to identify a dynamic text file in my source connection in SSIS.
eg. FileName is ABCYYYYMMDDtttt.txt.
Here ABC is file, YYYY is Year, MM is month, DD is date and tttt is TIME.
I am able to get to ABCYYYYMMDD using expressions.
how to identify tttt (TIME factor). It can be random every day.
eg. ABC20081203123245.txt (file received on 12/03/08)
eg. ABC20081204453467.txt. (file received on 12/04/08).
As we see in above 2 file names, date part can be recognized through expressions but time part is dynamic.
How to get around to identify these type of files in source connection?
December 8, 2008 at 2:34 pm
Is it permissable within your environment to use an upstream process to capture the dynamic file and copy or rename it to a known static name? That's how I've dealt with this type of issue when I've run into it.
December 8, 2008 at 2:36 pm
nope
December 8, 2008 at 2:48 pm
It would be awfully cludgy, but if you have file system access from your executing account, you could try putting some type of file watch process on your inbound data directory to capture the name of an inbound file, then build an XML config file on the fly that contains it.
December 8, 2008 at 8:23 pm
mm... I'm confused... you say the time format is "tttt", but you have six characters for the time in both examples and one of the sets of 6 looks like... 453467.
That's not a "time"... but it does look like it could be the number of milliseconds since midnight.
--Jeff Moden
Change is inevitable... Change for the better is not.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply