Larry Brouwer

... just my personal technology sandbox

  • About
  • Blog
  • Archives
  • Contact

Connect

  • Email
  • Facebook
  • LinkedIn

Powered by Genesis

Copying Sql Server 2008 database from Prod to Dev

December 29, 2010 By Larry Brouwer Leave a Comment

I had the pleasure of refreshing the development instance of the Harris County Master Gardener’s database this morning. Basically, Dev was getting too old to conduct testing on, so took the most recent Production backup (from last night), and using MS SSMS I was able to restore the database without much incident.

However, my troubles then began when I attempted to pull up the Development Web Site. The application couldn’t connect to the database. I’ve had this type of thing happen in the past, but as usual, I’ve forgotten how to fix it.

After some researching on the Web, I came up with a Microsoft Support Article entitled, Troubleshooting Orhpaned Users, and I was able to fix the problem with relative ease. Look under the section “Steps to Resolve Orphaned Users”.

The following are the steps I undertook:

1. Using MS SSMS, connect to the Sql Server instance where the copied database exists.

2. Open a New Query window and enter: Use DataB go sp_change_users_login ‘report’

3. The stored procedure will display output for all of the affected login’s

4. Open a New Query window and enter: Use DataB go sp_change_users_login ‘update_one’, ‘test’, ‘test’ for each login.

That should fix the problem!

Filed Under: Daily Log Tagged With: SqlServer

Leave a Reply

You must be logged in to post a comment.

Recent Posts

  • Weaver’s Bamboo “Bambusa textilis” clumping bamboo for sale
  • configuring NTP Service on FreeNas, XenServer, and virtualized Windows Server 2012 R2 Domain Controller
  • CentOS 7 Warning: Your Magento folder does not have sufficient write permissions.
  • AOE Scheduler 1.3.0 cron issue with Magento 1.9.2.2

Tag cloud

Outlook Connector SMTP Scanpst.exe eCommerce Windows Remote Desktop D-Link DIR-655 Maytag SSMS CentOS C# OfficeLive web.config Port 25 Exchange 2010 mstsc.exe .NET Framework PST Live Writer Silverlight Yahoo Mail SBS2011 Log Parser Windows 7 AWStats PrestaShop Blogs clumping bamboo DotNetNuke Visual Studio OpenCart IIS7 SqlServer redirect Database Mail Tools Security SVN iframe TomatoCart Neptune MySQL Azure SmarterMail BlogEngine.Net