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
 SQL Server Development (2000)
 Union stored procs

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2001-11-18 : 17:53:40
Jaydel writes "I have created 2 procedures with parameters and need to union the results together. I thought about using a temp table but Crystal Reports needs to know what the table is and there are 65 users running this process.

for example
_______________________
create PROCEDURE PAUnion @DocNum char(10) AS

ProjectAnalysisHLMProc @docnum
UNION ALL
ProjectAnalysisJCProc @docnum
_______________________

The 2 stored procedures return their results filtered for the docnum and then union themselves together. The crystal report is then connected to the PAUnion stored procedure.

Any suggestions?
If this has been covered somewhere, sorry, I looked but couldn't find anything.

Thanks much"
   

- Advertisement -