DDL Trigger

  • I am wondering if a DDL trigger can be written to grant db_datareader access to a given login each time a new database is created for the newly created database.

  • ...Since Model is used to create the new databases, if you set up a user to have datareader access in Model, by default that user will have datareader in every new database from then on....

    Look Ma - no Trigger!

    ----------------------------------------------------------------------------------
    Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?

  • WOW.... Thanks Matt. Guess I need to go back to the coffee machine. I tried to make this way too difficult.

  • Edogg (3/18/2008)


    WOW.... Thanks Matt. Guess I need to go back to the coffee machine. I tried to make this way too difficult.

    don't sweat it - it took me a long time to finally catch on to what Model is for... Just passing on the knolwedge!

    ----------------------------------------------------------------------------------
    Your lack of planning does not constitute an emergency on my part...unless you're my manager...or a director and above...or a really loud-spoken end-user..All right - what was my emergency again?

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

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