JustBeingHelpful
JustBeingHelpful

Reputation: 18980

Unable to reset stored procedure cache in SQL Server Management Studio 2008

Workflow:

I have two stored procedures. One stored procedure calls the other. When I first open SQL Server Management Studio, the child/nested stored procedure has no output parameters. Nor does my parent/calling stored procedure have an "OUTPUT" keyword on the argument when calling the child/nested stored procedure. And of course I'm not expecting any argument to be returned as output in my parent/calling stored procedure from the child/nested stored procedure.

Then I decided I need the returned value of the id that was inserted during that child/nested stored procedure, so I decided to put an "OUTPUT" keyword onto the parameter so that I can retrieve that value in the parent/calling stored procedure.

So I altered my child/nested stored procedure after adding an "OUTPUT" keyword on the end of the parameter. And clicked the "Execute" button in SQL Server Management Studio to save the stored procedure.

Then I added an "OUTPUT" keyword for the argument of my parent/calling stored procedure that matches up with the parameter of the child/nested stored procedure. Then I clicked the "Execute" button in SQL Server Management Studio to save the stored procedure.

Issue:

I have red underlines under my argument in the parent/calling stored procedure. The tooltip for the error says, "The formal parameter @donorid was not declared as an output parameter, but the actual parameter passed in requested output."

Workaround:

I can easily restart SQL Server Management Studio and it clears the cache and the red underlines go away, but I'd like to know the command that clears it without restarting.

PS: I'll post my stored procedures in separate posts so you have an example to work from.

Upvotes: 1

Views: 908

Answers (3)

JustBeingHelpful
JustBeingHelpful

Reputation: 18980

This is Microsoft Connect bug 668511.

Upvotes: 0

gbn
gbn

Reputation: 432511

To update Object Explorer one of:

  • right click on the "Stored Procedues" node and "Refresh"
  • left click, F5

To update Intellisense: ctrl + shift + R (also under Edit..Intellisense menu)

Upvotes: 1

Martin Smith
Martin Smith

Reputation: 453707

CTRL + Shift + R

Upvotes: 1

Related Questions