Error on using Cache Notifications on SQL Server 2008

Discussion in 'Databases' started by Guimel, Oct 27, 2010.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. Hallo,

    I wanted to use cache notification with sql Server 2008 in my application. Unfortunaly I got the following error:

    System.Web.HttpException: Unable to connect to the SQL database for cache dependency registration. ---> System.Data.SqlClient.SqlException:
    Login failed for user ...

    I think the problem is to enable notification on the server. How can I enable it for my database on the server?
     
  2. I found the problem: the pasword was missing in the ConnectionString of the query object.

    SqlCacheDependencyAdmin.EnableNotifications(query.Context.Connection.ConnectionString);

    It´s taken from the Web.config, but without the password. Unfortunatelly I don´t know why. However it´s solved.
     
  3. mjp

    mjp

    Thanks for the follow-up post.
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page