How to grant access to a local SQL Server database
The following steps describe how to grant access to the "Network Service" account to a local SQL Server database.
- Start SQL Server Management Studio.
- In the left panel, select the Security folder for your local SQL Server.
- Right-click on the Logins subfolder to open the context menu and click New Login.
- In the opened dialog box, enter NT AUTHORITY\NETWORK SERVICE in the Login name text box. Accept the defaults for the other settings and click OK.
- In the Databases folder, select your database.
- Right-click Users in the Security folder, and then click New User.
- In the opened dialog box specify the "NT AUTHORITY\NETWORK SERVICE" account.
- In the Role Members list, select the db_datareader check box.
- Click OK, and then close the SQL Server Management Studio.