次の方法で共有


ListMembers Method (SQLServer)

この機能は、将来のバージョンの Microsoft SQL Server では削除される予定です。新規の開発作業ではこの機能を使用しないようにし、現在この機能を使用しているアプリケーションは修正することを検討してください。

The ListMembers method returns a NameList object that enumerates the Microsoft SQL Server server or database roles in which the SQLServer object login has membership.

構文

object
.ListMembers(
Type
)
as
NameList

Parts

  • object
    Expression that evaluates to an object in the Applies To list.
  • Type
    Long integer that identifies a SQL Server role type constricting NameList membership as described in Settings.

Prototype (C/C++)

HRESULT ListMembers(
SQLDMO_ROLE_TYPE Type,
LPSQLDMONAMELIST* ppList);

Settings

Use the values enumerated below when setting the Type argument.

Constant Value Description

SQLDMORole_All

3

List server and database roles in which the connected login is a member.

SQLDMORole_Database

2

List database roles in which the connected login is a member.

SQLDMORole_Server

1

List server roles in which the connected login is a member.

Returns

A NameList object that enumerates system and user-defined security roles.

Applies To:

SQLServer Object