I was creating database diagram during one KT , and faced this issue in dev environment.
As soon as I tried to open the database diagram I faced following error. It was known for me so resolved it quickly, but better to do documented it for future reference.
Error
Database diagram support objects cannot be installed because this database does not have a valid owner. To continue, first use the Files page of the Database Properties dialog box or the ALTER AUTHORIZATION statement to set the database owner to a valid login, then add the database diagram support objects.
Workaround / Fix / Solution Execute below scripts on database
- ALTER AUTHORIZATION ON DATABASE::<database name>TO sa
- Select your database -->Right Click -->Select Properties
- Select FILE in left side of box
- In the OWNER box, select user ‘sa’ or NT AUTHORITY\SYSTEM
- Click OK.
This should solve your problem.
No comments:
Post a Comment