azure sql database

PowerShell – Add Azure AD group as User in Azure SQL Database

As an administrator, you may need to provide access to multiple people against multiple resources in Azure. One such example, is to provide access to an Azure SQL database. As a best practice, you might have created a separate Azure AD group to combine all the users that will need access to a Azure SQL database. Example, “Analytics_Devs” group need access to “Analytics-DB”. Similarly, we might have multiple combination of different Azure AD groups requiring access to different Azure SQL Databases.

The above task can be performed manually, however, it is tedious and error prone when it has to be done multiple times and repetitively.

As a solution to the above problem, I have written a PowerShell script that will automate the task for us. You can also use the PowerShell script as part of your CI/CD pipeline.


Download the script by clicking here.


Click here to download my PowerShell scripts for Free !!

Click here for Azure tutorial videos !!