Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
2 dummy questions
Message
From
03/09/1999 08:24:05
 
 
To
02/09/1999 21:57:34
General information
Forum:
Microsoft SQL Server
Category:
Stored procedures, Triggers, UDFs
Miscellaneous
Thread ID:
00258791
Message ID:
00261077
Views:
25
> ...I have more than 90 lines in one SQL statement (including select, where, group, order...)

That's a really big query! Just out of curiousity, why is it so big? Are you joining a lot of table together?

As to your original question, I still don't have a better answer than using an IF. You could place each query in a seperate stored procedure but I not sure if the result set would come back correctly if you called it from another stored procedure. Try it - maybe it will work. Or worst case, you could make two calls from the client (or middle-tier). One to look in the current data and one for history.

-Mike
Michael Levy
MCSD, MCDBA
ma_levy@hotmail.com
Previous
Reply
Map
View

Click here to load this message in the networking platform