Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?
From: Simon (nospam_at_nospam.nospam)
Date: 03/01/04
- Next message: Arn0s: "Re: Stored procedure;1"
- Previous message: Mihai Durcau: "Re: delete"
- In reply to: Roji. P. Thomas: "Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?"
- Next in thread: Andreas.Bretl: "Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?"
- Reply: Andreas.Bretl: "Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?"
- Messages sorted by: [ date ] [ thread ]
Date: Mon, 1 Mar 2004 15:56:38 -0500
Try to recompile the procedure using sp_recompile
"Roji. P. Thomas" <lazydragon@nowhere.com> wrote in message
news:OCRVUD4$DHA.2804@tk2msftngp13.phx.gbl...
> http://tinyurl.com/yw9ea
>
>
>
> --
> Roji. P. Thomas
> SQL Server Programmer
> "Andreas.Bretl" <bretl@brainlab.com> wrote in message
> news:c1v68f$1nif1q$1@ID-79490.news.uni-berlin.de...
> > Hi all,
> > I am currently facing a strange problem. I execute a stored procedure
(in
> > the query-analyzer)
> > EXEC MyProcedureThatIsSlow
> >
> > That takes ages.
> >
> > If I copy and paste the code of the procedure into the query-analyzer it
> > runs thousand times faster.
> >
> > I already looked at the "Estimated Execution Plan", inspected the
Indexes
> > but I can not figure out where the problem is.
> >
> > The only thing I see in the Execution Plan are some Parallelism-Tasks
but
> > this is not the first time I deal with those.
> >
> > Executing the procedure also does not put out the PRINT commands I used
> and
> > additionally the Trace-Output is in both tries the same (the one is just
> > slow).
> >
> > If anybody could point me into the right direction solving that I would
> > greatly appreciate that.
> >
> > Seize the Day
> >
> > Andy
> >
> >
> > Andreas Bretl
> > bretl@brainlab.com
> > Software Engineer
> > BrainLAB AG
> >
> >
>
>
- Next message: Arn0s: "Re: Stored procedure;1"
- Previous message: Mihai Durcau: "Re: delete"
- In reply to: Roji. P. Thomas: "Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?"
- Next in thread: Andreas.Bretl: "Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?"
- Reply: Andreas.Bretl: "Re: Stored Procedure executes very slow, code pasted into query-analyzer executes fast?"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|