Default database settings in the Login properties.

  • One of the users need access to the Database "ABC". There is an option in the "Login Properties" screen to provide the 'Default database".

    If I leave it as 'master' and don't change to 'ABC' what will happen? And, if I change the "Default Database" to the database name requested, "ABC", then what is going to happen?

    Pls explain the difference...

    Thanks.

  • I am sure you have a SQL Server right in front of you. Why not try it out. Also check BOL. You should be able to get enough info there...

    -Roy

  • Wao....what a suggestion!! I appreciate.

    Thanks.

  • As a side bar, the default is for SQL Server to give everyone a default of "Master" and that's how a lot of folks end up making stored procs in Master which is one of the big "Bozo-no-nos" in SQL Server.

    When I set up a server, I set the default database to a SandBox DB (or Temp DB if not allowed to do otherwise). There are certain individuals that require their own SQL Server logins instead of a Windows login and server role... I manage those default login database separately, of course.

    Bottom line... I think that leaving the default database set to Master is one of the worst things that can be done.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Ha,

    I thought I was the only one that set people's default to tempdb.

    everyone I run into gives me weird looks about it.

    Cheers!

Viewing 5 posts - 1 through 4 (of 4 total)

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