-1

Even Service Broker seems to be available for Azure SQL managed instance, I was able to activate it, when I run:

CREATE QUEUE ExpenseQueue;

, I get the error:

Statement 'CREATE QUEUE' is not supported in this version of SQL Server.

Any idea how to fix this?

bjnr
  • 3,353
  • 1
  • 18
  • 32
  • Are you sure you're on [Azure SQL Managed Instance](https://azure.microsoft.com/en-au/products/azure-sql/managed-instance/)? CREATE QUEUE is not available on other services such as [Azure SQL Database](https://azure.microsoft.com/en-au/products/azure-sql/database/). – AlwaysLearning Mar 24 '23 at 08:35
  • 1
    What's the output of `SELECT SERVERPROPERTY('EngineEdition');`? If it's not 8 then it's not Azure SQL Managed Instance. Ref: [SERVERPROPERTY](https://learn.microsoft.com/en-us/sql/t-sql/functions/serverproperty-transact-sql) – AlwaysLearning Mar 24 '23 at 08:42
  • @AlwaysLearning, EngineEdition is 5. Veeerry strange, indeed! – bjnr Mar 24 '23 at 08:48
  • 1
    Looks like it’s _not_ managed instance. So how did you configure and activate service broker before you got to the CREATE QUEUE step? – Aaron Bertrand Mar 24 '23 at 08:59

1 Answers1

0

Indeed, the Azure SQL wasn't a managed instance. Everything worked normal after setting up a managed instance.

bjnr
  • 3,353
  • 1
  • 18
  • 32