Re: sql2k5 schema qualifier



Thank you. I looked at this again and it is something else that we changed during the migration. What is now the schema MIS_TABLES used to be owner dbo. Duh.


Kalen Delaney wrote:
Hi Dave

If you do not specify a schema name, SQL Server will look in your default schema, then in the dbo schema.
This is very similar to what we happens in SQL Server 2000, in that unqualified objects are first checked to see if they are owned by the current user, then checked to see if they are owned by dbo.

Roles, permissions,etc do not help determine what schemas to check.

The reason is that there can be objects of the same name in different schemas (or in SQL 2000, owned by different users).
What if MIS and MIS_TABLES both included a table named foo_bar? Which one would you want?

Can you explain what behavior you saw in SQL 2000 that makes you say it was easy?

.



Relevant Pages

  • Re: sql server
    ... managment studio is connected to a sql server 2000 standard edition database. ... the default schema name for me on sql server 2005 management studio ... Assuming your database is using objects only in the dbo schema here is what ...
    (microsoft.public.sqlserver.setup)
  • Re: multiple cascade paths
    ... You should not have them if your schema is designed properly. ... make you understand that I tried to show that a proper design can have ... am a SQL Server MVP, for crying out loud - you can safely assume that I ...
    (comp.databases.ms-sqlserver)
  • Re: Need help on how to organize users and objects
    ... Yes Oracle is a bit different than Sql Server, but I think you will get the ... It doesnt become part of any schema until you assign it. ... a new developer started to work. ... need the COMMON database which stores tables with generic data and generic ...
    (microsoft.public.sqlserver.security)
  • RE: Please help with deleting a user.
    ... MCITP: Database Administrator ... it says that it can not alter "dbo" schema. ... I am new to SQL Server. ...
    (microsoft.public.sqlserver.security)
  • Re: 3 Simple Security SQL Statements
    ... In SQL 2005, when you create an object, you specify the schema that the ... Kalen Delaney, SQL Server MVP ... Schema for a database role, that seems like the best setup. ... EXEC sp_addrolemember 'WebUsersRole', 'WebUser' ...
    (microsoft.public.sqlserver.security)