Validate Método
Validates the package with the specified connection and determines whether the specified server is valid.
Espacio de nombres: Microsoft.SqlServer.Management.Dac
Ensamblado: Microsoft.SqlServer.Management.Dac (en Microsoft.SqlServer.Management.Dac.dll)
Sintaxis
'Declaración
Public Shared Function Validate ( _
server As Server, _
databaseName As String _
) As ExtractValidationException
'Uso
Dim server As Server
Dim databaseName As String
Dim returnValue As ExtractValidationException
returnValue = DatabaseExtractValidator.Validate(server, _
databaseName)
public static ExtractValidationException Validate(
Server server,
string databaseName
)
public:
static ExtractValidationException^ Validate(
Server^ server,
String^ databaseName
)
static member Validate :
server:Server *
databaseName:string -> ExtractValidationException
public static function Validate(
server : Server,
databaseName : String
) : ExtractValidationException
Parámetros
- server
Tipo: Microsoft.SqlServer.Management.Smo. . :: . .Server
A Server object specifying the server to validate.
- databaseName
Tipo: System. . :: . .String
A String value specifying the name of the database to validate.
Valor devuelto
Tipo: Microsoft.SqlServer.Management.Dac. . :: . .ExtractValidationException
A ExtractValidationException that specifies which problems were detected. Returns nullNothingnullptrunites una referencia NULL (Nothing en Visual Basic). if no problems were detected.
Comentarios
The Validate method checks to ensure that:
The server is not in Design Mode.
The database exists, and that information can be extracted from it.
The user has sufficient privileges to extract information from the database.
Vea también