[Last Call] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 414
  • Last Modified:

Importing a database with the same user as already on system.

Hi, my SQL install has a user called 'sitecore' with password '123'.
When I import a database (another MDF) from another machine that also had the user 'sitecore' but with a different password of 'oldpass' I cannot login.

On the imported machine trying both sitecore/123 or sitecore/oldpass does not work.

One solution I found was deleting the 'sitecore' user from the imported database and creating it again, but I don't want to do that. Is there a way to match these usernames up so I can login?
1 Solution
Paul JacksonCommented:
yes :

EXEC sp_change_users_login 'Auto_Fix', 'user'

dazkrazAuthor Commented:
Yes, but needs to be run on each database.

Featured Post

Efficient way to get backups off site to Azure

This user guide provides instructions on how to deploy and configure both a StoneFly Scale Out NAS Enterprise Cloud Drive virtual machine and Veeam Cloud Connect in the Microsoft Azure Cloud.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now