Sample script that displays all of the users in a given SQL Server DB

时间:2007-06-16    点击:111   
Sample script that displays all of the users in a given SQL Server DB.

Supported Platforms

SQL Server 2000
 Yes


Script Code

复制代码 代码如下:

strDBServerName = "." 
strDBName = "ScriptingGuysTestDB" 

Set objSQLServer = CreateObject("SQLDMO.SQLServer") 
objSQLServer.LoginSecure = True 
objSQLServer.Connect strDBServerName 

Set objDB = objSQLServer.Databases(strDBName) 
Set colUsers = objDB.Users 
For Each objUser In colUsers 
   WScript.Echo "User: "    & objUser.Name 
   WScript.Echo "Login: "   & objUser.Login 
Next 
List Information About the Binary Files Used by an Application
List the Codec Files on a Computer
Save a File Using a File Save Dialog Box
Locate a File Using a File Open Dialog Box
firefox中用javascript实现鼠标位置的定位
> 返回     
地址:上海市普陀区胶州路941号长久商务中心 电话: QQ:
© Copyright 2012 上海网络 Product All Rights Reserved