• Steve Jones - SSC Editor (3/22/2013)


    Are you saying you want a read only and a read/write role? Separate from db_Datereader/writer?

    That's easy to script.

    loop through all tables in all databases, grant rights to a standard named role (MyReadRole).

    Add users to the role.

    However if you want something that's not a pattern, you have to do it manually.

    Agreed on the manual aspect for the roles that don't follow a pattern.

    If a decision is made to grant access via stored procedures, the manual labor becomes a little easier.

    But I have to wonder - if you are looking to recreate db_datareader, why?

    Jason...AKA CirqueDeSQLeil
    _______________________________________________
    I have given a name to my pain...MCM SQL Server, MVP
    SQL RNNR
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events