Does the SQL Server 2005 CommandNotification cache dependency workwith stored procedures?

D

dherbstemail-ng

I can get the SQL Server 2005 CommandNotification cache dependency to
work with inline SQL. It works in a SqlDataSource as well as with the
page OutputCache when making ADO.NET calls.

Next I copy/paste the exact same inline SQL into a stored procedure
wrapper and switch my SqlDataSource or ADO.NET code to call the stored
procedure. Now the cache is no longer refreshed after data in the
query results has been changed.

Has anyone been able to get the SQL Server 2005 CommandNotification
cache dependency to work with stored procedures?

If so, is there anything special that need to be done to enable it to
work with stored procedures?

Thanks,
David
 
D

David Herbst

My standard stored procedure template contains SET NOCOUNT ON. It
turns out that this is not compatible with SQL Server 2005
dependencies. After removing it, cache dependencies work with my
stored procedures.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,580
Members
45,054
Latest member
TrimKetoBoost

Latest Threads

Top