The amazing adventures of Doug Hughes

This issue has plagued me since moving to SQL Server 2005. I find the diagram tools help me visualize my data and relationships. The problem is that with SQL 2005 sometimes you get this error when you try to create a new diagram:

Error

You can follow the instructions in the error message till the cows come home and still not be able to successfully create a diagram. This is true even if you set the owner to SA or some other administrator.

After much screaming and gnashing of teeth I finally learned that the problem isn’t really with the owner, it’s with the database compatibility level. Your database may be running in either SQL 7 or 2000 compatibility mode, not 2005.

To resolve the problem, in SQL Server Management Studio, right click on the database node and click Properties. Select Options on the left and set the compatibility level to SQL Server 2005 (90).

DB Props

Just make that change, click OK and you’re good to go.

Comments on: "Can't Create Diagrams in SQL Server 2005?" (18)

  1. Joshua Curtiss said:

    Very good to know. We have a 2000 and 2005 server at work, and I have yet to develop any apps fresh on the 2005 environment. This will save me the gnashing of teeth. 🙂

    Like

  2. thanks a lot..I struggled a lot with this error.nice solution

    Like

  3. Thanks a lot..struggled a lot with this error.Nice solution

    Like

  4. vaya puta mierda!

    Like

  5. This is verrryyyyy goood solution

    Thanque veryyyyyy much

    Like

  6. thank you

    Like

  7. Goodday every One,

    I have problem with sql 2005 and 2000 together,to great Database Diagrams. How?
    Now ? tell you how.
    I have two sql server in my machin, one of them is sql 2000 woking for Program “LOGO GO” and second server for me(I am studing in Course software Microsoft). My sql version 2005 and there ? cannt dowload upgrate anything(my friends say, due to sql 2000 server)
    and ? have sql2005(80), but havnt sql 2005(90). So what ? must to do , to break this problem.

    I will wait your reply

    Thank you Very much….

    Like

  8. I have the problem that this guid should fix, but in the database property option it is alredy sql 2005(90)??

    Like

  9. Doug Hughes said:

    Since writing this entry in February I also found this script somewhere on the web that has worked for me in every case:

    EXEC sp_dbcmptlevel ‘YourDatabase’, ’90’;
    go
    ALTER AUTHORIZATION ON DATABASE::YourDatabase TO “sa”
    go
    use YourDatabase
    go
    EXECUTE AS USER = N’dbo’ REVERT
    go

    Like

  10. Weee, thanks Doug Hughes, your solution worked.

    Like

  11. Alan Wong said:

    Great… your solution worked perfectly… thanks…

    Like

  12. thanks…

    Like

  13. Paul Moran said:

    Thanks, Doug. Worked like a charm! 🙂

    Like

  14. Shannon Tillery said:

    Very useful Doug. Many thanks.

    Like

  15. Bhupesh M said:

    Very useful my friend. Thanks.

    Like

  16. I tried the above mentioned solution but my db’s compatibility level is already at 90… I used the script as well but it doesn’t work. I’m the owner of the db but still it throws the same error. Plzzzzz if anyone could help!

    Like

  17. Very good!

    Like

  18. bespoke database design…

    […]Can’t Create Diagrams in SQL Server 2005? – Alagad Ally[…]…

    Like

Comments are closed.

Tag Cloud

%d bloggers like this: