|
Posted by maxvalery on 09/11/06 16:14
Hi,
I need to run a stored procedure with 2 parameters sixty-five (65)
times, each time changing one parameter incrementally.
E.g.
EXEC MyStoreProcedure 3, 1
EXEC MyStoreProcedure 3, 2
EXEC MyStoreProcedure 3, 3
....
EXEC MyStoreProcedure 3, 65
The result of each query should be put in a separate Excel file. The
name for each respective Excel file is stored in the same table from
which the incrementing parameter is pulled.
==========
In other words, there's a table MyTable with INDEX field 1 and PATH
field C:\MyExcelFile1.xls. The stored procedure to get the results to
be exported into that Excel files would be EXEC MyStoreProcedure 3, 1.
There's a table MyTable with INDEX field 2 and PATH field
C:\MyExcelFile2.xls. The stored procedure to get the results to be
exported into that Excel files would be EXEC MyStoreProcedure 3, 2.
There's a table MyTable with INDEX field 3 and PATH field
C:\MyExcelFile3.xls. The stored procedure to get the results to be
exported into that Excel files would be EXEC MyStoreProcedure 3, 3, and
so on.
==========
Is there any way to automate ANY PART of this conundrum from within a
DTS?
Thanks!!!
Navigation:
[Reply to this message]
|