I've done this before, but I cannot remember how.
I want to use the result set from a stored procedure in another stored
procedure....
In other words:
+ '%'
AND ID IN (******Results from P1*************)
HELP!!!!!!
I want to use the result set from a stored procedure in another stored
procedure....
In other words:
+ '%'
AND ID IN (******Results from P1*************)
HELP!!!!!!
One simple way to do this is to create a temp table in PS run the exec into
that table within P2 and then call that from the stored procedure select eg
go
create table #tempid (ID int)
AND ID IN (select ID from #tempid)
go
This should do what you want
I hope this was of use.
Stephen Robinson (SQL MVP)
>I want to use the result set from a stored procedure in another stored
>procedure....
>In other words:
>+ '%'
>AND ID IN (******Results from P1*************)
>HELP!!!!!!
Charlie Barrett
Flower Mound
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Does your PC get bored while you're away? A CPU is a terrible thing to waste, so take him to http://setiathome.ssl.berkeley.edu/
his CPU. Your PC will be processing Radio Telescope signals from Arecibo, using state-of-the-art DSP algorithms like FFT's and
Correlators. Then it uploads the results back to SETI (the Search for Extra-Terrestrial Intelligence)... I told you it was
cool!!!
And if your PC makes one of the most important discoveries of all time (a signal from a distant civilization), he will be the
envy of the Net, because the SETI team will give him credit in their worldwide press release (oh yeah, you'll get credit, too,
so you won't get jealous and make a scene).
I've done this before, but I cannot remember how.
I want to use the result set from a stored procedure in another stored
procedure....
In other words:
+ '%'
AND ID IN (******Results from P1*************)
HELP!!!!!!
1. using SQL stored procedure results in stored procedure
OK, here's a trick question I would love an answer to.
I want to use the result table generated by a stored procedure
in the stored procedure which called it.
It is possible to retrieve the result table created by a stored procedure,
if you use some external library (DB-Lib, ODBC, etc.); is it
possible to do from with in a stored procedure?
The specific example I am trying is:
- Have multiple transaction log dumps to a single dump file
- The transaction logs in the dump file are serialized (1,2,3...)
- I can use LOAD HEADERONLY FROM <dumpfile> to retrieve a table
listing the details (include the index numbers) in the output
screen (or from an external client), but I can't reference the output
from sql code.
There are other ways around this problem (which I have taken, which
are real *hacks*), but this is a common problem I run into: the info
I need I can get from a stored procedure, but I can't *use* the info
once I have it.
Any suggestions will be appricated.
3. Stored Procedure using another Stored Procedure
5. Using Stored Procedure's results in a Stored Procedure
6. VB/Access program loads wrong Jet DLL
7. Using the result from one stored procedure in a second stored procedure
9. Using Results Of Stored Procedure As Input Into Another Stored Procedure
10. Using stored procedures within stored procedures
11. Stored procedures problem using DB2 Stored Procedure Builder
12. Calling a Java Stored Procedure from another Java Stored Stored Procedure
13. storing the resultset from the stored procedure