盯着 sqldependency 时出现以下错误
找不到指定的用户“所有者”。找不到队列“SqlQueryNotificationService-dfb11997-c69e-4e3b-a640-29cdf4c3e9fa”,因为它不存在或者您没有权限。无效的对象名称“SqlQueryNotificationService-dfb11997-c69e-4e3b-a640-29cdf4c3e9fa”。
我已经授予了以下权限。不确定要授予 sql 角色/用户的其他权限。感谢您的时间和帮助
GRANT CREATE PROCEDURE to [SqlUser]
GRANT CREATE QUEUE to [SqlUser]
GRANT CREATE SERVICE to [SqlUser]
GRANT REFERENCES on
CONTRACT::[http://schemas.microsoft.com/SQL/Notifications/PostQueryNotification]
to [SqlUser]
GRANT VIEW DEFINITION TO [SqlUser]
GRANT SELECT to [SqlUser]
GRANT SUBSCRIBE QUERY NOTIFICATIONS TO [SqlUser]
GRANT RECEIVE ON QueryNotificationErrorsQueue TO [SqlUser]
GRANT ALTER ON SCHEMA::dbo TO [SqlUser]
GRANT CONTROL ON SCHEMA::[dbo] TO [SqlUser];
GRANT IMPERSONATE ON USER::DBO TO [SqlUser];
ALTER USER [sqluser] WITH DEFAULT_SCHEMA=[SqlUser]
GO