Showing posts with label diagram. Show all posts
Showing posts with label diagram. Show all posts

Tuesday, March 27, 2012

Database has invalid owner

I get this error when I try to view the database diagram. This is strange because it was about two weeks ago that I created and edited the database diagram. What is wrong with my login now as compared to when I did those edits?

The error suggests to use the ALTER AUTHORIZATION to change to a valid login. I am using windows authentication. If my login (the database ownere) is not the valid login then who is?

And what are the database diagram support objects that it suggests I install. I never heard of them, and where are they? Why didn't I need to install anything special when I worked on the diagrams two weeks ago?

Error message:

TITLE: Microsoft SQL Server Management Studio Express

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.

BUTTONS:
OK

Does anyone have any suggestions?

dbuchanan

Right click the database in question and select "properties". Select the "Files" from 'Select a Page' on the left side.

On the right side browse or add the owner that you want.

If things dont work then try using the sa owner. I also faced the same problem but when I sed the sa login then it worked wonders.

Xavier

sql

Database has invalid owner

I get this error when I try to view the database diagram. This is strange because it was about two weeks ago that I created and edited the database diagram. What is wrong with my login now as compared to when I did those edits?

The error suggests to use the ALTER AUTHORIZATION to change to a valid login. I am using windows authentication. If my login (the database ownere) is not the valid login then who is?

And what are the database diagram support objects that it suggests I install. I never heard of them, and where are they? Why didn't I need to install anything special when I worked on the diagrams two weeks ago?

Error message:

TITLE: Microsoft SQL Server Management Studio Express

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.

BUTTONS:
OK

Does anyone have any suggestions?

dbuchanan

Right click the database in question and select "properties". Select the "Files" from 'Select a Page' on the left side.

On the right side browse or add the owner that you want.

If things dont work then try using the sa owner. I also faced the same problem but when I sed the sa login then it worked wonders.

Xavier

Sunday, March 11, 2012

Database Diagrams, SQL Server 2005

Hi everyone,

I was wondering if there is any way to generate a database diagram with foreign key relationships automatically generated between tables in SQL Server 2005... My initial investigations has yielded no, but I'd like to be sure.

Thank you

Chris

The database diagramming tool won't automatically create foreign key contraints on your tables. You can explicitly create foreign key relationships in a diagram by clicking on one table and dragging the relationship line to the related table.

If you have two existing tables with a foreign key relating them, the relationship line should automatically display in the diagram as soon as you add both tables to the diagram.

Hope this helps,
Steve

|||Thank you very much Steve, very helpful.

Database diagrams problem

Hi, I restored my 2000 database in Microsoft SQL Management Studio 2005 but
a cannot reach the Database Diagram. I get the message:
--
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.
--
I used File pages but I don't know how to set a valid owner.
AKAssuming you don't have SP1 installed, then it's likely that your updated
database is still in 80 compatability level. See the Important note in this
Books Online topic (http://msdn2.microsoft.com/en-us/library/ms186345.aspx).
SP1contains a fix to this problem.
Gail Erickson [MS]
SQL Server Documentation Team
This posting is provided "AS IS" with no warranties, and confers no rights
Download the latest version of Books Online from
http://www.microsoft.com/technet/pr...oads/books.mspx
"Anatoly Kurilin" <akurilin@.nordsoft.ru> wrote in message
news:%23rhyXFotGHA.4852@.TK2MSFTNGP02.phx.gbl...
> Hi, I restored my 2000 database in Microsoft SQL Management Studio 2005
> but a cannot reach the Database Diagram. I get the message:
> --
> 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.
> --
> I used File pages but I don't know how to set a valid owner.
> AK
>

Database Diagrams on SQL 2000

So there is no way to create a Database diagram on a SQL 2000 database using
SQL Server management studio 2005 even though that database diagrams is not
a
new feature?
ThanksHi Lazer,
Thats right, you should use SQL Enterprise Manager to admin/create database
diagrams on SQL Server 2000.
You can use Management Studio only to create diagrams against SQL Server
2005 servers and databases.
Tony.
Tony Rogerson
SQL Server MVP
http://sqlserverfaq.com - free video tutorials
"Lazer" <Lazer@.discussions.microsoft.com> wrote in message
news:3F59CE7A-30EE-4D63-9F75-9341AF211698@.microsoft.com...
> So there is no way to create a Database diagram on a SQL 2000 database
> using
> SQL Server management studio 2005 even though that database diagrams is
> not a
> new feature?
> Thanks

Database Diagrams in SQL 2005

I have installed SQL Server 2005 Standard Edition... but I am unable to use the database diagram designer. I have tried the right click and the only options I have are refresh and help. Looking at the node, it is an empty folder...

Have I not installed this correctly or am I missing an important step along the way?

Thanks in advance for any info!

Sam

Which version of SQL Server are you running (Can be determined with SELECT @.@.Version)

HTH, Jens Suessmeyer.

-
http://www.sqlserver2005.de
-

Database Diagrams export

Hi, Can someone help me?
I need to create a tree structured diagram of our Server databases. I know how to create diagrams via the Enterprise manager, but I don't know how I can export them into some format, that I can further work with (doc., txt.,etc.). Is there some other tool, then the one in enterprise manager?
Thanks in advance.
Magdalena.That may be helpful:

Script SQL Server 2005 diagrams to a file

Database Diagrams

TITLE: Microsoft SQL Server Management Studio

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.


BUTTONS:

OK

I don't know what is the meaning of the above message, which I get when I 'right click' the Database Diagrams node of the Northwind database. Every thing seems OK, since I am the owner of this database.

I am using the trial version of MS SQL Server 2005.

Hi there,

Check the database compatability level for your database. To do this:

1) Right click on the desired database and select "Properties" from the context menu that appears

2) The "Database Properties" dialog box will appear on your screen. There will be an item on the left hand side of the dialog called "Options". Click on this.

3) The "Database Properties" dialog will change its appearance. There should be an entry in the dialog called "Compatability Level".

Now, from my experience, if the database compatability level is set to anything other than "SQL Server 2005 (90)" then diagramming won't work. You need to change the compatability level to "SQL Server 2005 (90)" if it is not currently set to this.

If that was your problem then after changing the compatability level you should be able to create database diagrams.

Also, while you have the "Database Properties" dialog open, it wouldn't hurt just to check that the owner is valid (if you have not already done so). You can check and edit the database owner by clicking on the "Files" item on the left hand side of the "Database Properties" dialog.

Hope that helps a bit, but sorry if it doesn't
|||

Thanks a lot for your reply

But unfortunately it did not work

I am using Windows Authentication when I log in. And when I click Files in the Database properties windows I find the owner is the same as the log in user.

|||did you create your database with detach/attach?|||

I did not create it

I do not remember, either I imported the database, or it came with the engine.

|||

you might want to eliminate the issue from your local instance by creating a new dummy database. If you have no problem with the new database, the issue might be caused by the source database you got.

I have noticed a similar issue after I shared my database in another machine.

|||

Nate -

Thanks for this post! That worked perfectly for me.

Regards,

Tim

|||

If there is no issue with a fresh database locally, the issue could be likely caused by credential inherited from external database when attached. I found out the similar issue in this scenario and resolved by doing the following,

Alter authorization on database::issue_database_name_here to [domain\user]

Just share my experience.

|||

Sorry, I was offline for few days.

Thank you for your replies. I'll try your solution.

Somebody suggested the following solution to me:

Use Northwind
EXEC sp_helpdb Northwind
EXEC Sp_ChangeDBOwner 'sa'
EXEC sp_helpdb Northwind

I don't have enough experience with SQL Server. So I wish to get your views about the above solution.

Database diagrams

I have just installed SQL server Express and am trying to create a database diagram. When I right click on database diagram, I just get the options to use help or to refresh. There is no option to create a new diagram,

Thanks,

Sarah

Express doesn't contain that option. You might try some of the freeware offerings to create database diagrams, or you can use Microsoft's Visio for Enterprise Architects.

Buck Woody

|||Can they not be created in the management studio?|||

Yes, but not against SQL Server Express.

Buck Woody

|||

I have now installed SQL server 2005 and need to be able to produce ERD's. Through the management studio, I do not ge the option to create new diagrams, I only get refresh or help. Should I be creating the some other way?

Thanks.

|||

No, you're in the right place. If you have installed a Standard Edition of SQL Server 2005 or higher, you will be able to create diagrams, but not against an Express database. Express databases don't have the ability to create the objects required for a database diagram. If you're using the 2005 tools to hit a 2000 database, you'll run into the same issue. You need to create 2000 diagrams in 2000.

|||i currently have the managemet studio express on my machine and there is support for creating database diagrams. if your are connecting to a remote server through the management studio it could be because of the security settings server side that will disallow the option. if you set up a local server it will give you the option

Database Diagrams

Do you need to be a member of the dbo role or an sa on a particular sql server to create a database diagram? I just want to confirm this is the case.
Any assistance will be helpful.
MariaYou have to logged as dbo or system administrator (sa or member of server group system administrators).|||Great, that's what I thought.

Thanks,

Maria|||Even if you are not a dbo or sysadmin, you can still create the diagrams and save them. But you will not be able to make changes to the tables as you don't have DML permissions.|||Okay, that is the problem. My developers can't seem to create a database diagram because the message is that they don't have sufficient permissions. Is there a particular role that they should be assigned to in order to do this? Or a level of permissions that is associated?

Maria|||Make sure the following stored procedures exist in the database:

dbo.dt_getobjwithprop_u
dbo.dt_adduserobject
dbo.dt_setpropertybyid_u
dbo.dt_getpropertiesbyid_u|||Great, I'll try that tomorrow and let you know.

Maria|||Hi,

The procs exist in the database. The problem is that my users are still unable to create the diagrams on the db. It claims they don't have enough permissions.

That's where the initial inquiry came into play. If this is wrong and they should be able to create a diagram regardless of the role they are grouped into on the db, then does anyone know what the problem is?

Maria

Database diagrams

Can a Database Diagram be imported or exported so that the schema can be
shown to someone that does not have Enterprise Manager installed on their
system?
If so what tools can do this?
No; you can do a screen capture or print to a PDF, perhaps.
Adam Machanic
SQL Server MVP
http://www.datamanipulation.net
"Jim Abel" <JimAbel@.discussions.microsoft.com> wrote in message
news:65C71846-71F2-4875-B0C8-79C18104F5CF@.microsoft.com...
> Can a Database Diagram be imported or exported so that the schema can be
> shown to someone that does not have Enterprise Manager installed on their
> system?
> If so what tools can do this?

Database diagrams

Hi
I'm trying to view a SQL 2000 Diagram that was created by my colleage. When
I click on "Design Diagram" it appears blank (ie it does show any of the
table links). However if I create a diagram I can view that and my colleage I
can view the diagram that I've created and my colleage can also view it.
Any ideas.
TIA
Dwight
Dwight,
Did you apply Visual Studio Service Pack 6?
If so, this has happened to many people. I don't know if
there is a knowledge base article or supported fix for the
issue. Others have reported working around the issue by
installing an older version of mdt2df.dll
-Sue
On Mon, 10 Jan 2005 03:47:03 -0800, Dwight
<Dwight@.discussions.microsoft.com> wrote:

>Hi
>I'm trying to view a SQL 2000 Diagram that was created by my colleage. When
>I click on "Design Diagram" it appears blank (ie it does show any of the
>table links). However if I create a diagram I can view that and my colleage I
>can view the diagram that I've created and my colleage can also view it.
>Any ideas.
>TIA
>Dwight
|||Hi Sue,
Yes I have install VS SP6. I'll see if I can find an old version of
mdt2df.dll and reinstall it.
Thanks
"Sue Hoegemeier" wrote:

> Dwight,
> Did you apply Visual Studio Service Pack 6?
> If so, this has happened to many people. I don't know if
> there is a knowledge base article or supported fix for the
> issue. Others have reported working around the issue by
> installing an older version of mdt2df.dll
> -Sue
> On Mon, 10 Jan 2005 03:47:03 -0800, Dwight
> <Dwight@.discussions.microsoft.com> wrote:
>
>

Database diagrams

Hi
How do i display database diagram in the web
try Visio
"SQL dba" <SQLdba@.discussions.microsoft.com> a crit dans le message de
news:54CE8681-4384-4889-91C5-4FFE1963076D@.microsoft.com...
> Hi
> How do i display database diagram in the web
>

Database diagrams

Is there a way to add a table that resides in one database to a diagram that
resides in another database?
SQL Servers database diagram tool only supports diagrams
using tables in the current database. If you use another
diagramming tool, one option would be to create a view of
the table in the other database. Other data modeling, ERD
tools support views in diagrams but not the tool built into
SQL Server..
-Sue
On Fri, 15 Oct 2004 09:33:03 -0700, "John"
<John@.discussions.microsoft.com> wrote:

>Is there a way to add a table that resides in one database to a diagram that
>resides in another database?

Thursday, March 8, 2012

Database diagrams

Hi
I'm trying to view a SQL 2000 Diagram that was created by my colleage. When
I click on "Design Diagram" it appears blank (ie it does show any of the
table links). However if I create a diagram I can view that and my colleage
I
can view the diagram that I've created and my colleage can also view it.
Any ideas.
TIA
DwightDwight,
Did you apply Visual Studio Service Pack 6?
If so, this has happened to many people. I don't know if
there is a knowledge base article or supported fix for the
issue. Others have reported working around the issue by
installing an older version of mdt2df.dll
-Sue
On Mon, 10 Jan 2005 03:47:03 -0800, Dwight
<Dwight@.discussions.microsoft.com> wrote:

>Hi
>I'm trying to view a SQL 2000 Diagram that was created by my colleage. When
>I click on "Design Diagram" it appears blank (ie it does show any of the
>table links). However if I create a diagram I can view that and my colleage
I
>can view the diagram that I've created and my colleage can also view it.
>Any ideas.
>TIA
>Dwight|||Hi Sue,
Yes I have install VS SP6. I'll see if I can find an old version of
mdt2df.dll and reinstall it.
Thanks
"Sue Hoegemeier" wrote:

> Dwight,
> Did you apply Visual Studio Service Pack 6?
> If so, this has happened to many people. I don't know if
> there is a knowledge base article or supported fix for the
> issue. Others have reported working around the issue by
> installing an older version of mdt2df.dll
> -Sue
> On Mon, 10 Jan 2005 03:47:03 -0800, Dwight
> <Dwight@.discussions.microsoft.com> wrote:
>
>

Database diagrams

Does anyone know if there is a way to export a database diagram from SQL
enterprise manager to either Microsoft visio or any other paint program?
thanx PapaniiHi,
The only way to export them out is via Copy and Paste or you can get a
graphic print driver (Postscript driver) and save the print to a file. Then
you may be able to import it into another program.
There is no option from SQL Sever to do this.
regards
Greg O
AGS SQL Server Documentation Builder - MS SQL Server
http://www.ag-software.com/ags_scribe_index.aspx
"Papanii Okai" <papanii58@.hotmail.com> wrote in message
news:uUesp8jBEHA.2600@.TK2MSFTNGP09.phx.gbl...
> Does anyone know if there is a way to export a database diagram from SQL
> enterprise manager to either Microsoft visio or any other paint program?
> thanx Papanii
>|||visio enterprise has the ability to Reverse Engineer your DB.
Visio will Build the ERD for you if you point it at your Database.
Greg Jackson
PDX, Oregon

Database diagrams

Can a Database Diagram be imported or exported so that the schema can be
shown to someone that does not have Enterprise Manager installed on their
system?
If so what tools can do this?No; you can do a screen capture or print to a PDF, perhaps.
Adam Machanic
SQL Server MVP
http://www.datamanipulation.net
--
"Jim Abel" <JimAbel@.discussions.microsoft.com> wrote in message
news:65C71846-71F2-4875-B0C8-79C18104F5CF@.microsoft.com...
> Can a Database Diagram be imported or exported so that the schema can be
> shown to someone that does not have Enterprise Manager installed on their
> system?
> If so what tools can do this?

Database diagrams

I have just installed SQL server Express and am trying to create a database diagram. When I right click on database diagram, I just get the options to use help or to refresh. There is no option to create a new diagram,

Thanks,

Sarah

Express doesn't contain that option. You might try some of the freeware offerings to create database diagrams, or you can use Microsoft's Visio for Enterprise Architects.

Buck Woody

|||Can they not be created in the management studio?|||

Yes, but not against SQL Server Express.

Buck Woody

|||

I have now installed SQL server 2005 and need to be able to produce ERD's. Through the management studio, I do not ge the option to create new diagrams, I only get refresh or help. Should I be creating the some other way?

Thanks.

|||

No, you're in the right place. If you have installed a Standard Edition of SQL Server 2005 or higher, you will be able to create diagrams, but not against an Express database. Express databases don't have the ability to create the objects required for a database diagram. If you're using the 2005 tools to hit a 2000 database, you'll run into the same issue. You need to create 2000 diagrams in 2000.

|||i currently have the managemet studio express on my machine and there is support for creating database diagrams. if your are connecting to a remote server through the management studio it could be because of the security settings server side that will disallow the option. if you set up a local server it will give you the option

Database diagrams

I have just installed SQL server Express and am trying to create a database diagram. When I right click on database diagram, I just get the options to use help or to refresh. There is no option to create a new diagram,

Thanks,

Sarah

Express doesn't contain that option. You might try some of the freeware offerings to create database diagrams, or you can use Microsoft's Visio for Enterprise Architects.

Buck Woody

|||Can they not be created in the management studio?|||

Yes, but not against SQL Server Express.

Buck Woody

|||

I have now installed SQL server 2005 and need to be able to produce ERD's. Through the management studio, I do not ge the option to create new diagrams, I only get refresh or help. Should I be creating the some other way?

Thanks.

|||

No, you're in the right place. If you have installed a Standard Edition of SQL Server 2005 or higher, you will be able to create diagrams, but not against an Express database. Express databases don't have the ability to create the objects required for a database diagram. If you're using the 2005 tools to hit a 2000 database, you'll run into the same issue. You need to create 2000 diagrams in 2000.

|||i currently have the managemet studio express on my machine and there is support for creating database diagrams. if your are connecting to a remote server through the management studio it could be because of the security settings server side that will disallow the option. if you set up a local server it will give you the option

Database Diagrams

TITLE: Microsoft SQL Server Management Studio

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.


BUTTONS:

OK

I don't know what is the meaning of the above message, which I get when I 'right click' the Database Diagrams node of the Northwind database. Every thing seems OK, since I am the owner of this database.

I am using the trial version of MS SQL Server 2005.

Hi there,

Check the database compatability level for your database. To do this:

1) Right click on the desired database and select "Properties" from the context menu that appears

2) The "Database Properties" dialog box will appear on your screen. There will be an item on the left hand side of the dialog called "Options". Click on this.

3) The "Database Properties" dialog will change its appearance. There should be an entry in the dialog called "Compatability Level".

Now, from my experience, if the database compatability level is set to anything other than "SQL Server 2005 (90)" then diagramming won't work. You need to change the compatability level to "SQL Server 2005 (90)" if it is not currently set to this.

If that was your problem then after changing the compatability level you should be able to create database diagrams.

Also, while you have the "Database Properties" dialog open, it wouldn't hurt just to check that the owner is valid (if you have not already done so). You can check and edit the database owner by clicking on the "Files" item on the left hand side of the "Database Properties" dialog.

Hope that helps a bit, but sorry if it doesn't
|||

Thanks a lot for your reply

But unfortunately it did not work

I am using Windows Authentication when I log in. And when I click Files in the Database properties windows I find the owner is the same as the log in user.

|||did you create your database with detach/attach?|||

I did not create it

I do not remember, either I imported the database, or it came with the engine.

|||

you might want to eliminate the issue from your local instance by creating a new dummy database. If you have no problem with the new database, the issue might be caused by the source database you got.

I have noticed a similar issue after I shared my database in another machine.

|||

Nate -

Thanks for this post! That worked perfectly for me.

Regards,

Tim

|||

If there is no issue with a fresh database locally, the issue could be likely caused by credential inherited from external database when attached. I found out the similar issue in this scenario and resolved by doing the following,

Alter authorization on database::issue_database_name_here to [domain\user]

Just share my experience.

|||

Sorry, I was offline for few days.

Thank you for your replies. I'll try your solution.

Somebody suggested the following solution to me:

Use Northwind
EXEC sp_helpdb Northwind
EXEC Sp_ChangeDBOwner 'sa'
EXEC sp_helpdb Northwind

I don't have enough experience with SQL Server. So I wish to get your views about the above solution.