Interview Question in SQL Server Integration Services


 

Interview Question :: SSIS SQL Server 2005


I need to read in a file that is created say every 30s and store the info into my database. Can SSIS file manager grab files of a certain type (*.txt) or does it need a full file name? Also when the package runs as a job will it only grab one file and then the job is completed or will it keep running as long as there are files in the folder?
Answers to "SSIS SQL Server 2005"
RE: SSIS SQL Server 2005?

You'll need to write a script to do some of what you want. For instance, you can use the folder object to get all the files in a folder. Then you can process all files or combine (read each file and write to one output file).



This is the way we do it where I work. We don't know how many files we'll get at one time. We grab the folder and each file in the folder and create a header, data and trailer file. We then move the input files to another folder so we don't process them again. We then have some processes that take the data and do whatever it does to it. All of this is done in a job.



I believe SSIS needs the file name. When we used DTS packages in SQL Server 2000, we needed the full file name. This is why we did it in a script.
 
Vote for this answer ::  
Update Alert Setting