In SQL Server, there is a user user1 who can access tables in databases AA and BB.
Then I want user1 not to access all other databases except AA, BB.
That is, user1 should not access any tables in any other databases except AA and BB.
user1should have access only toAAandBB- just create users foruser1only inAAandBBand that login will not be able to access any other databases on that server instance.