Initializes a new instance of the DatabaseMapping class for the specified login, database, and user.
命名空間: Microsoft.SqlServer.Management.Smo
組件: Microsoft.SqlServer.Smo (in microsoft.sqlserver.smo.dll)
語法
'宣告
Public Sub New ( _
loginName As String, _
dbName As String, _
userName As String _
)
public DatabaseMapping (
string loginName,
string dbName,
string userName
)
public:
DatabaseMapping (
String^ loginName,
String^ dbName,
String^ userName
)
public DatabaseMapping (
String loginName,
String dbName,
String userName
)
public function DatabaseMapping (
loginName : String,
dbName : String,
userName : String
)
參數
- loginName
A String value that specifies the login.
- dbName
A String value that specifies the database.
- userName
A String value that specifies the user.
備註
This namespace, class, or member is supported only in version 2.0 of the Microsoft .NET Framework.
範例
How to: Enumerate Logins and Associated Users in Visual Basic .NET
平台
開發平台
如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。
目標平台
如需受支援的平台清單,請參閱<安裝 SQL Server 2005 的硬體和軟體需求>。
請參閱
參考
DatabaseMapping Class
DatabaseMapping Members
Microsoft.SqlServer.Management.Smo Namespace