Skip to content

How to update all objects in a table to DBO

Neat, elegant little script to update all objects in a table (back) to dbo:

EXEC sp_msforeachtable "sp_changeobjectowner '?', 'dbo'"

SHARE THIS POST: