|
|
|
Grasshopper
      
Group: General Forum Members
Last Login: Monday, March 25, 2013 9:57 AM
Points: 22,
Visits: 77
|
|
Hello,
I have a SSIS package that pulls files down from an FTP site and loads the files into basic SQL tables. At the moment this package runs everyday at 3:00pm. I have to check the folder to see if a specific file was uploaded to determine when the FTP upload process ends. Currently I have a simple timer script set up that checks the folder every 15 minutes to see if the file has been uploaded.
My question is... How resource intensive is this method? If the file doesn't upload for several hours will this kill performance on my production box? Here is the script that I have in a SSIS scripting task...
WHILE (select count(*) from TABLE where DATE >= GETDATE()) = 0 BEGIN WAITFOR DELAY '00:15:00' END;
|
|
|
|
|
SSCertifiable
       
Group: General Forum Members
Last Login: Today @ 1:46 PM
Points: 6,730,
Visits: 11,783
|
|
From a T-SQL perspective WAITFOR DELAY will not actively use any server resources other than the overhead of having it keep an open thread using a little memory for the request and having it effectively do nothing.
From an SSIS perspective, if it issued the T-SQL batch out of a Script Task then the SSIS package will remain running. So again, it won't be actively using CPU or doing I/O, but it will be occupying memory on your server.
PS I am confused though. You say that you check a folder every 15 minutes but then you show a SQL batch. Are we talking about an SSIS Package checking a folder or a T-SQL process checking table?
__________________________________________________________________________________________________ There are no special teachers of virtue, because virtue is taught by the whole community. --Plato
Believe you can and you're halfway there. --Theodore Roosevelt
Everything Should Be Made as Simple as Possible, But Not Simpler --Albert Einstein
The significant problems we face cannot be solved at the same level of thinking we were at when we created them. --Albert Einstein
1 apple is not exactly 1/8 of 8 apples. Because there are no absolutely identical apples. --Giordy
|
|
|
|
|
Grasshopper
      
Group: General Forum Members
Last Login: Monday, March 25, 2013 9:57 AM
Points: 22,
Visits: 77
|
|
T-SQL process checking a table.
Thanks so much for your response!
|
|
|
|