Solved

SQL SERVER Enterprise Manager Login Name Blank

Posted on 2007-12-04
3
565 Views
Last Modified: 2008-02-01
In SQL Server Enterprise Manager > Database > (Database Name) > users
I have a user that has a blank LOGIN NAME.  I need to associate this with one of our domain accounts.  

At one point in time this Database user was associated with a domain account.  The domain account was deleted at one point.  Since then I recreated the account and would like to reassociate the db user with this nt account.  

I tried deleting the user on the database level and readding by going to Enterprise Manger > Security.  It adds the user ok but the LoginName still turns out blank.
0
Comment
Question by:9413systems
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 17

Accepted Solution

by:
Chris Mangus earned 500 total points
ID: 20407140
You also need to delete the user at the database server level...Enterprise Manager > Security.  Then, re-add the account.

If you delete a domain account and don't take it out of SQL Server it will be an orphan account.  SQL Server matches domain account on the SID, not the user name.  If you create a new account on your domain with the same name as the old one it gets a new, unique SID.
0
 
LVL 1

Author Comment

by:9413systems
ID: 20407187
Is there any way to associate a orphan account with a new windows account??
0
 
LVL 17

Assisted Solution

by:Chris Mangus
Chris Mangus earned 500 total points
ID: 20407236
For SQL logins, yes, for domain logins, no.  For domain accounts you always have to drop and recreate the account in SQL Server because of the SID issue.

With SQL logins you'd use sp_change_users_login 'AUTO_FIX','username'
0

Featured Post

Comparison of Amazon Drive, Google Drive, OneDrive

What is Best for Backup: Amazon Drive, Google Drive or MS OneDrive? In this free whitepaper we look at their performance, pricing, and platform availability to help you decide which cloud drive is right for your situation. Download and read the results of our testing for free!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Introduction In my previous article (http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/SSIS/A_9150-Loading-XML-Using-SSIS.html) I showed you how the XML Source component can be used to load XML files into a SQL Server database, us…
A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
This video shows, step by step, how to configure Oracle Heterogeneous Services via the Generic Gateway Agent in order to make a connection from an Oracle session and access a remote SQL Server database table.
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.

739 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question