PROPERTY:  Connection::Provider

string = connectionobject.Provider
connectionobject.Provider = string


The Provider property is used to set or return the name of the provider for a specific Connection object. The default is MSDASQL (Microsoft OLE DB provider for ODBC).
 
The provider name can also be set using the ConnectString property of the Connection object and the ConnectString parameter of the Open method. You should never set the provider for a specific Connection in more than one place.
 
Obviously, setting an invalid provider will generate an error.
 
Provider Codes
 
Provider Code Provider
ADSDSOObject Active Directory Services
Microsoft.Jet.OLEDB.4.0 Microsoft Jet databases
MSDAIPP.DSO.1 Microsoft Internet Publishing
MSDAORA Oracle databases
MSDAOSP Simple text files
MSDASQL Microsoft OLE DB provider for ODBC
MSDataShape Microsoft Data Shape
MSPersist Locally saved files
SQLOLEDB Microsoft SQL Server


Code (VBScript):
Set objConnection = Server.CreateObject("ADODB.Connection")
objConnection.Provider = "Microsoft.Jet.OLEDB.4.0"
...
objConnection.Open strConnect

Copyright 1999-2001 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information