SQL Server Broker

I've been playing with SQL Server Broker services to allow me to notify my C# code when some data has been changed, but first you need to enable SSB (SQL Server Broker).  The easiest way of doing this is to us the following SQL statement:

alter database [<dbname>] set enable_broker with rollback immediate;

The reason for using rollback immediate is that the statement needs to have exclusive access to the database, and any connection has a shared lock on it, even when idle.

blog comments powered by Disqus

About the author

You have probably figured out by now that my name is Bryan Avery (if not, please refer to your browser's address field).  Technology is more than a career to me - it is both a hobby and a passion.  I'm an ASP.NET/C# Developer at heart...

Month List