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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 sp_recompile

Author  Topic 

poser
Posting Yak Master

124 Posts

Posted - 2008-08-26 : 13:56:21
I have an old application that in the stored procedures it has a SELECT *
When we add new columns into the table the stored procedures does not include this new column.
If I go and re-save the stored procedure it works fine.
Can I use the sp_recompile to accomplish the same thing without any other implications?
Any other suggestions other than rewriting the app?
Thanks, P

jhocutt
Constraint Violating Yak Guru

385 Posts

Posted - 2008-08-26 : 14:13:20
The best answer is to re-write the app select * should not be used.
The reason you are experiencing now.



"God does not play dice" -- Albert Einstein
"Not only does God play dice, but he sometimes throws them where they cannot be seen."
-- Stephen Hawking
Go to Top of Page

poser
Posting Yak Master

124 Posts

Posted - 2008-08-26 : 18:26:10
Any other suggestions besides the obvious to rewrite the application?
Is there any repercussions in running the sp_recompile on the stored procedures when needed?
Thanks, P
Go to Top of Page

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2008-08-26 : 19:04:18
Schema changes will cause your sp to recompile.It will affect the performance.
Go to Top of Page
   

- Advertisement -