469,338 Members | 8,424 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,338 developers. It's quick & easy.

Add new users to SQL Server mdf

How can i add new users to the sql server mdf. Since, when i try to
access the mdf it gives me
the following error under the setting "Windows Authentication":

" Could not open default database.Login failed for user AMIRDIWAN
\Administrator"

Alternatively, i tried the other way by keeping "SQL SERVER
Authentication":

" Login failed for user 'amirdiwan'.The user is not associated with a
trusted SQL Server connection."
How can i fix this. Please let me know, as i have to do it for my
final year project?

Mar 24 '07 #1
2 2283


"weird0" <am********@gmail.comwrote in message
news:11**********************@d57g2000hsg.googlegr oups.com...
How can i add new users to the sql server mdf. Since, when i try to
access the mdf it gives me
the following error under the setting "Windows Authentication":

" Could not open default database.Login failed for user AMIRDIWAN
\Administrator"

Alternatively, i tried the other way by keeping "SQL SERVER
Authentication":

" Login failed for user 'amirdiwan'.The user is not associated with a
trusted SQL Server connection."
How can i fix this. Please let me know, as i have to do it for my
final year project?
First, although this is homework, I don't imagine solving this particular
problem is part of the assignment.

What version of SQL Server are you using? What version of Windows?

Is the instance of SQL Server on your local computer?

Do you have another local administrator account that you can try to connect
from?

David

Mar 24 '07 #2
"weird0" <am********@gmail.comwrote in message
news:11**********************@d57g2000hsg.googlegr oups.com...
How can i add new users to the sql server mdf. Since, when i try to
access the mdf it gives me
the following error under the setting "Windows Authentication":

" Could not open default database.Login failed for user AMIRDIWAN
\Administrator"

Alternatively, i tried the other way by keeping "SQL SERVER
Authentication":

" Login failed for user 'amirdiwan'.The user is not associated with a
trusted SQL Server connection."
How can i fix this. Please let me know, as i have to do it for my
final year project?

SQL server logins aren't "Windows logins", so if you are using Windows authentication
(integrated security) you'll have to create windows accounts, when using SQL logins you have
to create SQL accounts. Note that you can also confifigure SQL server to use both SQL and
WIndows authentication, in which case you can use a mix of both.

Willy.
Mar 25 '07 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

24 posts views Thread by Jim Hubbard | last post: by
6 posts views Thread by Hannu | last post: by
4 posts views Thread by Kittikun | last post: by
10 posts views Thread by Jamunt | last post: by
1 post views Thread by CARIGAR | last post: by
1 post views Thread by haryvincent176 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.