Home All Groups Group Topic Archive Search About

Pass Parameter to Stored Procedure In .bat file

Author
7 Jul 2005 7:56 PM
A. Robinson
I'm sure the answer to this is very easy:

I have a .bat file that calls a stored procedure. This stored procedure
takes one input parameter. I have created a DTS package to call this .bat
file. What I would like to do is to be able to pass the parameter to the
stored procedure via the "EXECUTE PROCESS TASK" I created to call the .bat
file.

I ask this so that no one has to go in and fiddle with the actual .bat file,
just change the parameter value in the EXECUTE TASK PROPERTIES.

Hope that made sesne!

Thanks!!

Author
7 Jul 2005 8:00 PM
Aaron Bertrand [SQL Server MVP]
Wouldn't it be easier to create something clickable (WSH script, EXE, etc.)
that prompts for the parameter and then builds the batch file (and
optionally executes it)?  Why would someone who can't modify a batch file be
fully capable of navigating the DTS GUI?




Show quote
"A. Robinson" <ARobin***@discussions.microsoft.com> wrote in message
news:42AB0CCE-573C-42DD-85BB-0762ADE1D842@microsoft.com...
> I'm sure the answer to this is very easy:
>
> I have a .bat file that calls a stored procedure. This stored procedure
> takes one input parameter. I have created a DTS package to call this .bat
> file. What I would like to do is to be able to pass the parameter to the
> stored procedure via the "EXECUTE PROCESS TASK" I created to call the .bat
> file.
>
> I ask this so that no one has to go in and fiddle with the actual .bat
> file,
> just change the parameter value in the EXECUTE TASK PROPERTIES.
>
> Hope that made sesne!
>
> Thanks!!

AddThis Social Bookmark Button