[英]Roles user BD Geo Azure without access error 916
In SQL Azure, The roles of the users created in the main database are not replicated or copied to the geo database and generate error 916在 SQL Azure 中,在主数据库中创建的用户的角色未复制或复制到地理数据库并生成错误 916
enter image description here在此处输入图像描述
Can you help me?你能帮助我吗?
Could you please help me with a solution to this error, so that the user hosted in the GEO database can access his database with his role assigned in the main database.你能帮我解决这个错误吗,这样托管在 GEO 数据库中的用户就可以访问他在主数据库中分配的角色的数据库。
The roles of the users created in the main database are not replicated or copied to the geo database.
在主数据库中创建的用户角色不会复制或复制到地理数据库。
To create and access users from primary data base to replicated database follow below steps.要创建和访问从主数据库到复制数据库的用户,请按照以下步骤操作。
First follow below steps on the master
database of the Primary server:首先在主服务器的
master
数据库上执行以下步骤:
CREATE LOGIN [Login_name] WITH PASSWORD = 'secure-password'
CREATE USER [User_name] FOR LOGIN [Login_name]
ALTER ROLE dbmanager ADD MEMBER [User_name]
SELECT sid FROM sys.sql_logins WHERE name = '[User_name]'
Now follow below steps on the source
database of the Primary server:现在在主服务器的
source
数据库上执行以下步骤:
CREATE USER [User_name] FOR LOGIN [Login_name]
ALTER ROLE db_datareader add MEMBER [User_name]
Now, create login on the master
database of the Secondary server:现在,在辅助服务器的
master
数据库上创建登录名:
CREATE LOGIN [Login_Name] with password = 'secure-password', sid=0x010600000000006400000000000000003C5857161B989940886580923D14E710
Output输出
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.