[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

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

Invalid Object Name 'owner.table' on DELETE

Im using MS Sql Server 2000 under Windows XP.  We have Rainbow Portal v1.6 installed at work as well as at home.  What I've done is made a backup of the database from work and restored the database on my home server.  The restoration was successful however every table, stored procedure, view, etc ha its owner set to "chase" my name at work.  The Rainbow portal refused to work until i switched the owner to "dbo".   I did this with the following stored procedure on every table, stored proc, view, etc:

EXECUTE sp_changeobjectowner 'chase.FunctionName','dbo'

Rainbow Portal worked fine after that.  The problem Im now having is I try to remove an invalid entry in one of the tables and i consistently receive the error message:

[Micrsoft][ODBC SQL Server Driver][SQL Server] Invalid object name 'chase.rb_EnchancedHtml_st'

I've tried disabling relationships amongst some tables but the error message just changes to yet another table name.  It never ends.

Is there a way to resolve this whole "chase" owner issue from the backup/restore phase so that the owner is "dbo" completely with no mention of "chase" anywhere in the database file?  Even if theres a fix i can apply to my current database I'd take it.

  • 3
1 Solution
instead of restoring the database,

 delete your current database
 get the original .MDF and .LDF files
 put them in your data directory
 use the Attach Database Option by right clicking databases and choosing all tasks
 when the dialog comes up browse to the .MDF File and select it
 then change the Specified Database Owner to sa

once it is attached, it should work just fine.
did you also check triggers on table?
ljaquesAuthor Commented:
yes i checked triggers but nothing listed.
ljaquesAuthor Commented:
I do like the mdf/ldf copy approach however when i attempt to copy the 2 files i get a "cannot copy xxx. sharing violation" error message.  I dont want to stop the sql server on the production server just to make a copy.  Is there a way around this sharing violation on copying?
ljaquesAuthor Commented:
Whoops there were some triggers with the rian name in it.  Adjusted and all is fine now. thanks

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

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