Re: Developer design Best Practices

From: Dan Guzman (guzmanda_at_nospam-online.sbcglobal.net)
Date: 09/11/04


Date: Sat, 11 Sep 2004 10:42:23 -0500

The database owner login is a special case and is not specified like a
regular user. You can execute sp_changedbowner to specify the owner or
correct the mapping following a restore or attach:

    USE MyDatabase
    EXEC sp_changedbowner 'PIMDevDBO'
    GO

-- 
Hope this helps.
Dan Guzman
SQL Server MVP
"Amanda" <Amanda@discussions.microsoft.com> wrote in message 
news:C9078D21-D0C3-468E-A328-FC0AB622B95F@microsoft.com...
> OK - this is REALLY  freaky.
> Since there is only me as a dba, I can't go with the option of scripting 
> all
> their objects in dev.  We do that for production and test - they develop 
> them
> and then I move them, and the owner is dbo.
>
> There is NO DBO User in our dev database!!
>
> It simply doesn't show up in the GUI.  Of course it exists in the system
> table.
> I was planning to map a PIMDevDBO login to the "dbo" user.  I'm sure this
> can be done via SQL, but it is pretty freaky that dbo isn't showing up.
>
> we have moved this database all over - but I've never seen this happen
> before.  When I run sp_change_users_login it doesn't show up in report, 
> nor
> can I fix it.
>
> Do you guys think I should be concerned??
> 


Relevant Pages

  • Re: conflicting object names in sql server 2000
    ... The owner of the object will depend on the user ... On the local database server when it does the select * from ... she must specify the owner: ...
    (microsoft.public.sqlserver.server)
  • Re: not creating tables as dbo anymore ?
    ... Database Owner (dbo) ... existing user ID in the database specified by database_name. ... with the login of the current connection. ...
    (microsoft.public.sqlserver.security)
  • Re: Change UDF Owner
    ... Does it exist in the master database? ... Users can be put in the dbo role, but dbo will still own objects ... concept of 'schema' as 'owner' rather than just schema as DDL is exploited ... to the appropriate Fixed Server Roles or whatever is applicable. ...
    (microsoft.public.sqlserver.security)
  • Re: Change UDF Owner
    ... system_function_schema -especially in the master database. ... Most good judgment comes from experience. ... dbo is in the context of a database, and can be the schema owner for the ... Users can be put in the dbo role, ...
    (microsoft.public.sqlserver.security)
  • Re: conflicting object names in sql server 2000
    ... On the local database server when it does the select * from ... > michael.xxx Note that michael is the owner of the database. ... it will see if there is one owned by dbo. ...
    (microsoft.public.sqlserver.server)