SQL Server – How to Bulk Add Users from Active Directory

active-directoryimportSecuritysql serverusers

I would like to import all users from Active Directory into Security/Users.

What I do is the following:

  • Go to Security -> Users
  • Right click Users -> New User…
  • User type: Windows user, click on '…' at User Name
  • Define object type to User and location to my Active Directory one
  • Click on Find Now

Now I can see all users in this specific domain. What I cannot do is select more than one user from this list (e.g. by holding shift). So basically I would have to do it user by user. Since there are many users that would take a long time. And I am also wondering that there should be a 'smarter' way to do it.

Am I missing something? Am I doing something wrong?

Thanks for the help!

Best Answer

Am I missing something? Am I doing something wrong?

It's unusual to add a large number of individual active directory logins to a SQL Server. Instead add logins for Active Directory Groups to take care of most of your users.

See, eg: https://stackoverflow.com/questions/5029014/how-to-add-active-directory-user-group-as-login-in-sql-server