Ask Paula!

...bringing you notes from the field...
posts - 55, comments - 17, trackbacks - 0

My Links

News

Article Categories

Archives

Post Categories

.NET Development

Enterprise Integration

Java Development

Mobile/PDA Development

Professional Affiliations

How do I change the owner of my table in SQL Server?

Go to the ms sql server database instance that has the table object and open a new query window. Execute the system stored proc called sp_changeobjectowner. The 2 parameters it needs to run are: (1) the current owner+object name and (2) the target owner. Take a look at the example below:

exec sp_changeobjectowner 'METRO\paula.EmployeeContact', 'dbo'

When the stored proc is completed, refresh the instance. The table will then be owned by dbo. In this example, the table would display as dbo.EmployeeContact

Print | posted on Wednesday, August 27, 2008 10:40 AM | Filed Under [ SQL ]

Feedback

No comments posted yet.
Post A Comment
Title:
Name:
Email:
Website:
Comment:
Verification:
 
 

Powered by: