HAS_DBACCESS (Transact-SQL)
SQL Server 2005
Returns information about whether the user has access to the specified database.
Transact-SQL Syntax Conventions
Reference
IS_MEMBER (Transact-SQL)IS_SRVROLEMEMBER (Transact-SQL)