June 22, 2011 at 4:50 pm
I created a stored proceedure and forgot the the Close and Deallocate Cursor instructions 🙁
Can someone tell me how to manually do it.
Thanks
Michael Hilligas
June 23, 2011 at 8:56 am
Not sure I understand your question.
I'd drop and recreate the stored procedure with those commands added to it.
June 23, 2011 at 9:00 am
Thanks.....That is a solution.
I thought there was a way to close and deallocate manually.
I may be wrong.
I have already fixed it.
Take care
Regards
Michael Hilligas
June 24, 2011 at 2:12 pm
This begs the question....do you really need the cursors in the first place? There are very few reasons or situations where a cursor is needed. With very few exceptions a set based solution can be created which will increased performance in unbelievable magnitudes. Let us know if you want to explore removing the cursors and making your code faster.
_______________________________________________________________
Need help? Help us help you.
Read the article at http://www.sqlservercentral.com/articles/Best+Practices/61537/ for best practices on asking questions.
Need to split a string? Try Jeff Modens splitter http://www.sqlservercentral.com/articles/Tally+Table/72993/.
Cross Tabs and Pivots, Part 1 – Converting Rows to Columns - http://www.sqlservercentral.com/articles/T-SQL/63681/
Cross Tabs and Pivots, Part 2 - Dynamic Cross Tabs - http://www.sqlservercentral.com/articles/Crosstab/65048/
Understanding and Using APPLY (Part 1) - http://www.sqlservercentral.com/articles/APPLY/69953/
Understanding and Using APPLY (Part 2) - http://www.sqlservercentral.com/articles/APPLY/69954/
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply