Solved

Move SQL Database to new server, user transfers but can't assign permissions

Posted on 2011-03-09
4
589 Views
Last Modified: 2012-05-11
I have a database I'm developing an ASP application on a staging server for that I now need to move to a production server.   I detached the database and copied over to the new server (SQL express 2008).  The database uses SQL Authentication to access via the ODBC connection and the original user transfers over from the old server when I look under the users of the database.  However it appears the password doesn't follow. Under the users of the database there isn't a way to change/modify the user and it doesn't show as a user under the SQL server.

If I try and add the user under the server it will not allow me to map the user to the database with an error that the user already exists.  What and how do I need to make this work?  Sorry I don't have that much experience with SQL server (obviously).
0
Comment
Question by:rjilek
  • 2
  • 2
4 Comments
 
LVL 17

Accepted Solution

by:
xDJR1875 earned 500 total points
ID: 35089031
First, Delete the user from the database.
Second, Add the user under the server to the database.

0
 

Author Comment

by:rjilek
ID: 35089115
That kind of basically worked in a complicated way.  I could not just delete the user as it was an owner of some schema.  So I had to create a temp user to assign the schema to and then allow me to delete the user under the database.  Then I could create the user again under the server and reassign the schema to it under the database.  Anyway it worked and thanks the the hints and the quick reply!
0
 

Author Closing Comment

by:rjilek
ID: 35089125
The solution was critical in getting me to think in the right direction.
0
 
LVL 17

Expert Comment

by:xDJR1875
ID: 35089243
There are other ways of doing this, a system stored procedure(can't remember the name) can map a migrated user to a current user, but not sure if that is available for sql express.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Naughty Me. While I was changing the database name from DB1 to DB_PROD1 (yep it's not real database name ^v^), I changed the database name and notified my application fellows that I did it. They turn on the application, and everything is working. A …
SQL Server engine let you use a Windows account or a SQL Server account to connect to a SQL Server instance. This can be configured immediatly during the SQL Server installation or after in the Server Authentication section in the Server properties …
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

747 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

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now