User Access to databases

  • Hello 

    I am trying to set up some security on a login.

    I only want this person to be able to select from a view but the tables are on a different database from the view.

    The error i get is The server principal "xxxxxx" is not able to access the database "xxxxxxx" under the current security context.

    So far i have set up a user on the database where the the tables are held. Do i also need to set up a user on the database where the view is held?

    The login on the server level is also mapped to both databases if that helps.

    Please let me know if you need any more info.

    Thanks

  • The minimum permissions the user will need will be:

    Select on the view itself.
    Select permissions on any tables referenced by the view, that are not in the local database.

    Users will have to be created in any database that permissions are granted in.

    To make your future life easier, you will likely want to collect these permissions and assign them to a role, so if you need to do this for a second user, it will go much easier.  Of course, you have to remember how many databases to assign those permissions in.

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

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