I need to access the results of stored procedure sp_1 inside of stored
procedure sp_2.
sp_1 takes three parameters and returns a result set of data.
Help. Thanks!
Keith Messing
I need to access the results of stored procedure sp_1 inside of stored
procedure sp_2.
sp_1 takes three parameters and returns a result set of data.
Help. Thanks!
Keith Messing
Use :
Create Table #temptable (.......)
Insert Into #temptable
Execute sp_name
Now you can access the data from the temp table.
> sp_1 takes three parameters and returns a result set of data.
> Help. Thanks!
> Keith Messing
Instead of passing a temp table name you can insert the resultset into a
temp table in sp2 using the results set of the sp as input for an insert.
This is introduced in 6.5.
INSERT [INTO]
{table_name | view_name} [(column_list)]
You can also use this with remote stored procedures, so you can return a
result set from a different SQL Server.
1. Calling Stored Procedure that calls Stored Procedure in ASP
2. Oracle Object -- Stored Procedure Question
3. Calling a Java Stored Procedure from another Java Stored Stored Procedure
4. Why would 2 schemas in same instance with identical tables and data display 10 fold diff in speed
5. Stored Procedure calling Stored Procedure
7. Call a stored procedure from another stored procedure
8. full screen run time windows
9. Calling a stored procedure with parameters from another stored procedure
10. Calling a Stored Procedure from a Stored Procedure
11. How to call an Oracle Stored procedure from MSSQL Server Stored Procedure
12. Calling a stored procedure with parameters from another stored procedure
13. Stored procedure calls multiple stored procedures