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.
Author |
Topic |
SamC
White Water Yakist
3467 Posts |
Posted - 2003-11-19 : 10:56:00
|
Set p_objRS = Server.CreateObject("ADODB.Recordset") Set p_objRS = p_objConn.Execute(p_strCommand)Surrounding the two lines above with timer calls shows it is taking about 29 seconds to execute.Executing the identical command in Query analyzer is less than 0.5 second.This sounds like a connection pooling issue to me. Any thoughts about what might be going on?Sam |
|
SamC
White Water Yakist
3467 Posts |
Posted - 2003-11-19 : 11:32:21
|
I dropped the procedure and created it again. Now ASP renders the page in 1 second. Problem fixed.I have no idea why. Got to have something to do with locating the procedure?Sam |
|
|
MichaelP
Jedi Yak
2489 Posts |
Posted - 2003-11-19 : 11:42:21
|
It might be that the cached execution plan sucked. When you re-created the proc, the execution plan was re-created.Michael<Yoda>Use the Search page you must. Find the answer you will.</Yoda> |
|
|
SamC
White Water Yakist
3467 Posts |
Posted - 2003-11-19 : 11:45:33
|
Except it ran fine from Query Analyzer.The proc name wasdbo.QR_DeptcompletionsThere were 3 other "test" versions of the procdbo.QR_Deptcompletions2dbo.QR_Deptcompletions3dbo.QR_Deptcompletions4I deleted these 'test' versions, and recreated the first. I wish I had done it a step at a time.Sam |
|
|
robvolk
Most Valuable Yak
15732 Posts |
Posted - 2003-11-19 : 20:13:44
|
Running something from query analyzer will 99.99% of the time generate a new plan, so it will almost always be the most optimal plan. |
|
|
|
|
|