One of our databases has at some point in its dark past had the owner of the guest schema changed to be a named user, rather than the default guest user. Correcting this feels like it would be easy enough by running the following...
ALTER AUTHORIZATION ON SCHEMA::guest TO guest but that results in.. Msg 15150, Level 16, State 2, Line 3 Cannot alter the schema 'guest'.
I realise the guest schema is a special one, and cannot be dropped, but I'm not trying to do that. End goal is to export the database to a SQL Azure DB, and this guest schema assignment is blocking that process from completing.
Hello,I'm using tableadapters in VWD 2005 Express to link our ASP.NET application to a SQL Server 2000 database. Initially, I used Database Explorer to drop tables into the DataSet object, which picks up the owner of the tables from the database.Recently, we had to change the owner of all objects in the database, including tables and stored procedures. When we run our application it chokes on stored procedures because the owner of the SP's has changed. My question is: how can I update tables and tableadapters in the DataSet to reflect the change in owner, without having to recreate everything in DataSet?
Hi,I just transferred my website and database (SQL 2000) to a new host who's SQL Manager doesn't support the previous username I had for the database.The previous owner of database tables etc was Database_master and now I want to change it to just Master.Please advise! Someone else designed the website for me, and honestly I have just some basic knowledge of databases and such.I would appreciate help and if possible with detailed steps.Many thanks in advance,Isje
I restored and renamed a client database from a backup file to my laptop (both SQL Express 2005) and noticed that no owner had been assigned. I set the db-owner to SA. This database will replace a local version of the same database that was created on my laptop. (The customer has entered data...)
When I start the dataset configuration wizard in VS2005 all tables appear twice in the list. Once with the original name and once with the prefix dbo. For example: Customer and dbo.Customer.
The tables with the dbo. prefix are marked with a Red Cross in the checkbox. Hovering over them display the error message: "Element .. in the dataset references an object missing from the database. "
The tables without the dbo. prefix are not marked. When I mark these tables VS2005 indicates that the table will be renamed to Customer1. The same issue applies to all the views in the database.
Is there a way to solve this problem without having to recreate the entire dataset? I'd rather not do that cause I added some queries to the dataset and they will be lost and have to be recreated.
Hi, it has to do with my unfamiliarity with creating users and dbo privileges. I'm trying to grant access to an outside vendor to import their latest version of a database. I set them up with a user account that had db_owner privileges, however when they ran the dts process it copied all the data as new tables rather than overwriting the existing tables and the new tables were all associated with the user is created instead of dbo user. What do I need to do to facilitate this process?
I am in the process of cleaning up the security on one of our production databases. SA is already the owner of the database.
On this SQL server, there is a login that has access to this database that needs to be removed. When I uncheck this users access to this database I receive the following error message: "Error 15183. The user owns objects in the database and cannot be dropped".
How can i find out what objects this logins has ownership of and how can I change the ownership of these objects to SA?
We have a situation where somehow several of the system databases are owned by an ID of a person no longer with the organization. This triggers a few questions: If I disable the user (it's a SQL account, not domain), will that cause any issue? What is the correct way to change the user of a system database?
I can't change the database owner..I noticed this when I went to create a database diagram and the error said the database does not have a valid owner.
So for that database I went to Properties > Files and sure enough, the owner is wrong. Why? I had changed the name of the PC recently, actually a couple of times. When I finally got the name right, I ran the following commands in the query window:
SELECT @@SERVERNAME to get the current server name and then sp_dropserver <old name>
to change the server name.The owner in the Properties > Files is for a pc name that doesn't exist. But when I click on the '...' button to the right to select a new Database Owner I can't select the primary account on the PC.If I create a new database, it puts that old name in as the database owner.
I went down to <server>SecurityLogins and the old <pcname><username> is still listed, and I can't add the <newpcname><username> because it says that principle already exists . I'm afraid to make any other change without knowing for certain what to do.how to get a new database owner name on all the databases on this server.Do I delete that old Login and then try to add in the new name?
hi, I just imported my access database into sql server 2000 and apparently during this importation the owner was set to my name. This gives my a problem retrieving the data in asp.net though. I found out that the problem (System.Data.SqlClient.SqlException: Invalid object name 'tablename') is situated at this ownership by stripping the query to a bare minimum and trying it on a new table created in sql server with dbo as the owner. My problem now is that I can't seem to find the way to change the owner to dbo from 'peterj'. Can you help me on this one ??
I have several Production Databases on my SQL Server 2000 Standard Edition Server (mixed mode authentication) that I'd like to change DBO Permissions on. When I look at the Properties of the DB(s) from EM, the Database owner is showing up as a Windows NT USer who is no longer even with the company!!
Can I use the sp_changedbowner 'sa' command to change the database owner to sa without disrupting Production? Might sound like a dumb question.. but ya never know!!!!! Also, I had someone on another forum tell me that 'sa' as db owner is a bad idea but I don't know why??????? can anyone elaborate on that?????
I need to change the owner of all stored procedures from x to y. I know there is a sp_changeobjectowner sp, which does that, but in that way I will have to write a loop to get all sps which are owned by user x. Can somebody help me with that?
We set up a few tables while being logged in as a different user. Now, those tables are not accessible via some ASP pages because they aren't DBO-owned tables. Relationships do exist on these tables, but no significant data. Is there a way to change the owner, or do I need to delete the table and start over?
Using SQL Server 7.0Trying to change an objects ownership to dbo withEXEC sp_changeobjectowner 'AssignInvoiceNumbers', 'dbo'which gives the following error:Server: Msg 15001, Level 16, State 1, Procedure sp_changeobjectowner,Line 26AssignInvoiceNumbers does not exist.which it does.Any help would be greatly appreciated--Nath(Email mangling obvious)*** Sent via Developersdex http://www.developersdex.com ***Don't just participate in USENET...get rewarded for it!