Schemas - for a developer box?

  • We are setting up a sql2005 developer box. I've studied the Adventureworks database tables. Very nice how they use schemas to "scope" tables for select groups (e.g. "Accounting", "Human Resources"). But what schemas, if any, would you recommend  for consideration on a developer’s box?.

    Tia,

    Bill

     

    (We generally have a database for each application -- often a single department -- or several departments needing the same information. The value of schemas, in general, is not that clear to me.)

  • This depends on your persepective. First of all, if you put it on the dev boxes be prepared to put it on the Prod boxes, because once the developers start referencing objects on a given schema you'll need to use it in Prod also, or change the code (there is a way to do it without changing code, but is much more complicated).

    Using multiple schemas in a given DB requires good planning on how they will be used and how they fit into the overall security architecture. You must decide if you really need them, and are they really going to be useful in your security architecture.

    Another thing that complicates things and causes confusion is if someone creates a table in the wrong scema, and it duplicates a table in another schema. Depending on the schema the user has access to, how it's referenced, and the user's default schema, they could access the wrong table.

    For the moment, until I actually have something that requires that complicated a security architecture, I will be using only the dbo schema in my 2005 DBs.

    Chris

  • Thanks, Chris. That's exactly what I was thinking. Until the need is apparent I'm using the dbo schema only.

    TIA,

     

    Bill

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply