When using SQL Server to Do data mining, the user can not access the problem, so to the corresponding database add a login user Zhang, and give the appropriate permissions. When debugging, found that there is still a problem, so want to delete this user Zhang, and create a new user. An error message appears :
The database principal has a schema in the database and cannot be deleted. (Microsoft SQL Server, error : 15138)
Solution:
Delete the schema for this user, and then delete the corresponding user
Specific steps:
1, the corresponding database --"Security --" framework, first delete the corresponding framework
2, the corresponding database --"Security --" users, delete the corresponding user
The procedure is as follows:
Create user Zhang:
Delete User error:
Delete the appropriate schema:
User Deletion succeeded:
SQL Server 2008 appears that the database principal owns the schema in the database and cannot be deleted. (Microsoft SQL Server, error: 15138)