USE [pacsdbname]
GO
Alter database pacsdbname set enable_broker with rollback immediate;
GO


--GO
--CREATE QUEUE ImageFileChangeMessages;
--CREATE SERVICE ImageFileChangeNotifications
--  ON QUEUE ImageFileChangeMessages
--([http://schemas.microsoft.com/SQL/Notifications/PostQueryNotification]);
--GRANT SUBSCRIBE QUERY NOTIFICATIONS TO pacserver;
--GRANT RECEIVE ON [ImageFileChangeMessages] TO pacserver;
--GRANT SEND ON SERVICE::[ImageFileChangeNotifications] to pacserver;
--GO
