PDA

View Full Version : Moved database to new SQL Server



ecotutor
2010-01-20, 09:40 PM
I have exported data from my old SQL 2000 database and imported it into a new SQL 2000 database on a different server. The new database has a different name. I successfully restored the data from the previous database to the new one but I cannot access the database when on my website. It would appear that the name change has caused some problems as it stated there is an "orphaned user" when i restored the database. Tech support said to run an SQL query as follows:

exec sp_changeobjectowner ‘olduser.dbtable‘, ‘dbo’

I have found the myhosting.com SQL admin page but do not know where or how to run an SQL query, or what parameters to enter into the above string. Do I run this once for every table in the store or just once for the whole database? My old user name is user_89EB7F. My new username is DB_E663EC. Can anyone help me with the syntax of the query and how to run it?

Thanks for any help that you can give me.