View Single Post
  #10 (permalink)  
Old 03-08-2010, 06:45 AM
trentonponder trentonponder is offline
Member
 
Join Date: Jan 2009
Posts: 59
Default

Quote:
Originally Posted by forumsupport View Post
Hello,

Apologies for the inconvenience. What we suggest is, as a part of task, create a temporary folder, copy the file with modified date in last 30 days, loop for that temp folder and update sql and at the end delete that temporary folder. That way is reliable and faster. Below is the text format of task.


Create Folder "C:\Temp"

Copy Files "C:\SourceFolder\*.*" to "C:\Temp\" if file is modified in last 30 days

Start Loop " Each File in C:\Temp"

SQL SELECT using $FileName$
Loop through SQL
IF $Database Column(1)$ includes "xxxxx" then
SQL Insert
SQL Update
Email
End Loop


End Loop

Delete Folder "C:\Temp"

Hope that helps.
I don't see how this is any faster then:
If file modified in last 30 days
Blah Blah
End If


In both scenarios it still needs to examine every File. Is there not a way, to only loop through the files modified in last 30 days?
Reply With Quote