|
Posted by masri999 on 09/22/06 04:50
What you can do is create another SP (Parent SP)which is a wrapper on
the current SP .
Read the files one by one in the main SP and call your SP .
In DTS flow replace the current SP with Parent SP.
Srinivas
Alex wrote:
> Hello,
>
> I have a stored procedure that processes an individual file from a
> directory and archives it in a subdirectory.Now, the problem is, when i
> execute it , it will only process one file. What i want to do is to check
> to see if there are any files in the folder, and if there are , process
> them all, and once done, go to the next part in a DTS package, if there are
> no files, simply go to the next part in the DTS package. I tried an activex
> script that would get the filecount in the folder, and if there were more
> than 0 files in the folder, then DTS-sUCCESS and on "success" workflow , it
> would run the stored procedure, and thus it woould process one file, then
> "on completion" the workflow connected it back to the activeX script(thus
> looping), which would count the files again. Now if there were 0 files, it
> would report DTS_FAILIURE, and I had it set up ,"on failiure" to go to the
> next step in the package, but it wouldn't run.
>
> Someone mind showing me a ray of light?
Navigation:
[Reply to this message]
|