Q:

SQL Server 2008 Login Problem

I'm trying to install yet another forum on my local machine, and while I'm configuring the database connection I got this message 

Failed to connect:
Login failed for user 'NT
  AUTHORITY\NETWORK SERVICE'.

I have served Google and I found that I have to add network service Login to my SQL server and then add this user to my database
I don't know if this is true or false but anyway I don't know hot to add the network service to my SQL server
please help as soon as you can 
Thanks in Advance

A:

This is the Identity of the Appplication Pool in IIS
Local database, same box as IIS:
CREATE LOGIN [NT AUTHORITY\NETWORK SERVICE] FROM WINDOWS;

Local or remote database in Active Directory domain
CREATE LOGIN [myDomain\ServerName$] FROM WINDOWS;

A:

Goto SQL Server Management Studio => Security. Right click on Logins => New Login.
In Login name type NT AUTHORITY\NETWORK SERVICE. Click ok.  
Now click on your yaf database => Security. Right click on users => New User...
Fill in the username your desired name. in Login name type NT AUTHORITY\NETWORK SERVICE. Choose db_owner in Schemas and Database Role Membership click ok.  
You should be able to login to your databse with your desired username and password.

