SQL Server Performance Forum – Threads Archive
Run Queries in ParallelHi, I need small help in reducing the time taken by stored procedure to send output as resultset to client application. I have stored procedure which return four resultset by executing four queries i.e. Q1,Q2,Q3 and Q4. All queries returns 50,000 rows with 30 columns (30 columns are mandatory as per client requirement).
Now issue is that queries is taking lots of time to execute i.e. approx 2 to 3 min and much of the time are taken in sending output i.e. first Q1 resultset, second Q2 resultset, Q3 resultset and last Q4 resultset.I want to reduce the time taken to output the resultset . Can i execute Q1,Q2,Q3 and Q4 at the same time ?. Any way to reduce the time ?. Thanks and Regards
Client app can start the queries in separate connections, then combine the results.
http://technet.microsoft.com/en-us/library/ms178065(SQL.90).aspx &http://blogs.msdn.com/craigfr/archive/2006/10/11/introduction-to-parallel-query-execution.aspx fyi on the subject. Satya SKJ
Microsoft SQL Server MVP
Writer, Contributing Editor & Moderator
This posting is provided AS IS with no rights for the sake of knowledge sharing. Knowledge is of two kinds. We know a subject ourselves or we know where we can find information on it.