Share via

SQL Server SSMS中,建立兩位A、B者及兩個資料庫A、B如何讓A登入只看到A資料庫顯示出來,且針對A資料庫只有唯讀權限

永翊 林 0 Reputation points
2023-11-09T06:05:03.2466667+00:00

各位前輩好

目前有一個問題:
SQL Server SSMS中,建立兩位A、B者及兩個資料庫A、B
如何讓A登入只看到A資料庫顯示出來,且針對A資料庫只有
唯讀權限。

SQL Server | Other
SQL Server | Other

Additional SQL Server features and topics not covered by specific categories

0 comments No comments

2 answers

Sort by: Most helpful
  1. 永翊 林 0 Reputation points
    2023-11-09T07:03:15.83+00:00

    Hi Percy Tang

    I need when user A login ssms only can see A database show up

    and user A can not see B database. and A user have

    Read-only permissions on A database.

    Was this answer helpful?


  2. Anonymous
    2023-11-09T06:35:42.5566667+00:00

    Hi @永翊 林

    Read-only permissions: You can use db_datareader database role.

    https://learn.microsoft.com/en-us/sql/relational-databases/security/authentication-access/database-level-roles?view=sql-server-ver16

    如何讓A登入只看到A資料庫顯示出來

    Do you need A to be unable to access database B?

    Best regards,

    Percy Tang

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.