Last post Jul 11, 2019 09:06 AM by Jenifer Jiang
Jul 11, 2019 06:03 AMfirstname.lastname@example.org|LINK
i wrote this code to enable database i get this error
alter database Breeze_ERP51
set Enable_broker with rollback immediate
The Service Broker in database "Breeze_ERP51" cannot be enabled because there is already an enabled Service Broker with the same ID.
Jul 11, 2019 09:01 AM|PatriceSc|LINK
IMO for this kind of question a specialized SQL forum such as https://social.technet.microsoft.com/Forums/sqlserver/en-us/home?category=sqlserver or https://social.msdn.microsoft.com/Forums/sqlserver/en-US/home?category=sqlserver could
For now I suspect you perhaps have a copy of this database with the same broker id enabled already or something like that ? (though frankly I'm not familiar at all with that). µI would start by inspecting the current configuration using views such as https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/service-broker-catalog-views-transact-sql?view=sql-server-2017
Jul 11, 2019 09:06 AM|Jenifer Jiang|LINK
The Service Broker in database "Breeze_ERP51" cannot be enabled because there is already an enabled Service Broker with the same ID
This error happens when a Service Broker enabled database is restored or copied to the same SQL Server instance where the original database resides.
As a result, both databases end up having the same Service Broker identifier.
When we try to enable Service Broker for the restored database, we will receive this error message.
You could try to do the following to reinitialize the Service Broker identifier:
ALTER DATABASE [Breeze_ERP51] SET NEW_BROKER
For more about the issue, you could refer to the link below: