This is a discussion on How to target the file name with date variable ? within the C# Programming forums, part of the Software Development category; Hi.. My client will upload a file to a FTP folder regularly, but the time pattern is unknown, only thing ...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
| |||
| Hi.. My client will upload a file to a FTP folder regularly, but the time pattern is unknown, only thing I know is he'll use today's date as the file name. for example, he uploaded a file 'wk070705_id.txt' today, but I don't know when the next file will be uploaded. So how can i write a package like, every time when he upload a new file (for example if he upload a file 'wk070708_id.txt'), I can import the data into my table? I am a very newbie of SIS; it would be perfect if I can get a full script for this. Thanks in advance with appreciation! ps: the date in file name is yymmdd |
| Sponsored Links |
| |||
| Hi... I have given some explanation for your query.. Hope this helps... 1. One way i can think of is to make use of gateway service to poll that directory and as soon as file arrives, parse the file name and load the corresponding package. 2. If you have normal file system access to the folder then you can use this task -http://www.sqlis.com/23.aspx If you only have FTP access then polling is the way to go. You can request the file, but nee dto make the parameter dynamic based on todays date, for which you can use a property expression. Have a look in Books Online for the references to property expressions in SSIS they are what make it flexible and dynamic. Some example date expressions - Expression Date Functions |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Convert a date in milliseconds back to a date string | itbarota | HTML, CSS and Javascript Coding Techniques | 2 | 03-03-2008 09:03 PM |
| How can I show the documents last modified date in the format: month, date, year, tim | Pvinothkumar | HTML, CSS and Javascript Coding Techniques | 3 | 12-28-2007 05:58 AM |
| How to find the Starting date of week from a particular date | kingmaker | C# Programming | 1 | 08-16-2007 11:25 PM |
| How to convert a date to a globally accepted date format, in DOT NET 2005? | Archer | C# Programming | 1 | 07-25-2007 03:21 AM |
| Static Global Variable and Static Local Variable | vigneshgets | C and C++ Programming | 1 | 05-30-2007 11:50 AM |