Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 Using multiple SPs in one "Execute SQL Task"

Author  Topic 

yukito
Starting Member

1 Post

Posted - 2008-01-02 : 21:23:57
I have some (say, 3) stored procedures, and they all have the same one parameter. Each SP returns a dataset. I need to import each dataset to a table using DTS.

So, I created an "Execute SQL Task" and typed in "SQL Statement" something like this:

INSERT INTO TABLE TABLE1
EXEC SP1 ?
GO
INSERT INTO TABLE TABLE2
EXEC SP2 ?
GO
INSERT INTO TABLE TABLE3
EXEC SP3 ?
GO

And the execution return an error: No value given for one or more required parameters.

Is it possible to assign a parameter to all three SPs?

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2008-01-03 : 22:49:56
What's '?' here?
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2008-01-07 : 09:33:24
Did you pass the same parameter thrice one for each SP? the DTS actually maps the paramters based on information given on mapping tab and you should ensure you repeat the same param thrice one for each place holder(?)
Go to Top of Page
   

- Advertisement -