Click here to view and discuss this page in DocCommentXchange. In the future, you will be sent there automatically.

SAP Sybase SQL Anywhere 16.0 (中文) » SQL Anywhere 服务器 - SQL 参考 » 视图 » 兼容性视图

 

SYSGROUPS 兼容性视图

对于每组的每一个成员,在 SYSGROUPS 视图中都有与之对应的一行。该视图介绍了组与成员之间的多对多关系。一个组可以有许多成员,而一个用户也可以是许多组的成员。

在以下的 SQL 语句中提供了组成该视图的表和列。要了解有关特定表或列的详细信息,请使用该视图定义下所提供的链接。



ALTER VIEW "SYS"."SYSGROUPS"( group_name,
  member_name ) 
  as select g.user_name,u.user_name
    from SYS.ISYSROLEGRANT,SYS.ISYSUSER as g,SYS.ISYSUSER as u
    where ISYSROLEGRANT.role_id = g.user_id and ISYSROLEGRANT.grantee = u.user_id and(
    u.user_name in( 'SYS_SPATIAL_ADMIN_ROLE' ) 
    or u.user_id <= 2147483648) and(
    g.user_type = (0x02|0x04|0x08)
    or g.user_name in( 'SYS','PUBLIC','dbo','diagnostics',
    'rs_systabgroup','SA_DEBUG','SYS_SPATIAL_ADMIN_ROLE' ) )
 另请参见