Connecting to Azure SQL Database: Requested tenant identifier ‘00000000-0000-0000-0000-000000000000’ is not valid.

4

May 20, 2020 by Kenneth Fisher

The other day I got this rather interesting error while connecting to an Azure SQL DB.

I was connecting using Azure Active Directory – Universal with MFA authentication.

Unfortunately my Google/Bing-fu wasn’t up to the task of finding a post with the answer. But, after a bunch of searching and testing I did manage to figure it out for myself, so that was good. Simply enough the Active Directory Admin wasn’t set for the Azure SQL Server. If you go to the Overview tab for the server you’ll see this over on the right side.

Notice that it currently shows the Active Directory Admin as Not configured. To configure it just click on Not configured or the Active Directory Admin tab under Settings. That will take you to here:

From there just hit Set Admin at the top and pick the user or group that will be the admin. Since there can only be one admin, I highly recommend using a group if this is for work. That way multiple people can have access at the same time (for those that have a multi person DBA team this is essential IMO) and because people come and go in any job. This way it’s simple enough to change the membership of the group and not have to change every Azure SQL Server any time your DBA changes. For personal use this is far less important of course.

4 thoughts on “Connecting to Azure SQL Database: Requested tenant identifier ‘00000000-0000-0000-0000-000000000000’ is not valid.

  1. Kris H. says:

    Great post! Helped me solve this Azure Tenant problem very quickly as one of the first Google results.

  2. notarian says:

    This is the one Justin says helped him.

  3. Erwin says:

    Very good tip, many thanks.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Enter your email address to follow this blog and receive notifications of new posts by email.

Join 3,755 other subscribers

Follow me on Twitter

ToadWorld Pro of the Month November 2013
%d bloggers like this: