AdoNetAppender ConnectionType Property | Apache log4net™ SDK Documentation

Gets or sets the type name of the IDbConnection connection that should be created.

Namespace: log4net.Appender
Assembly: log4net (in log4net.dll) Version: 2.0.8.0-.NET 4.0
Syntax

C#
VB
C++
F#
Copy

    public string ConnectionType { get; set; }

    Public Property ConnectionType As String
    	Get
    	Set

    public:
    property String^ ConnectionType {
    	String^ get ();
    	void set (String^ value);
    }

    member ConnectionType : string with get, set

#### Property Value

Type: String
The type name of the IDbConnection connection.
Remarks

The type name of the ADO.NET provider to use.

The default is to use the OLE DB provider.

Examples

Use the OLE DB Provider. This is the default value.
Copy

    System.Data.OleDb.OleDbConnection, System.Data, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089

Examples

Use the MS SQL Server Provider.
Copy

    System.Data.SqlClient.SqlConnection, System.Data, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089

Examples

Use the ODBC Provider.
Copy

    Microsoft.Data.Odbc.OdbcConnection,Microsoft.Data.Odbc,version=1.0.3300.0,publicKeyToken=b77a5c561934e089,culture=neutral

This is an optional package that you can download from http://msdn.microsoft.com/downloads search for ODBC .NET Data Provider.
Examples

Use the Oracle Provider.
Copy

    System.Data.OracleClient.OracleConnection, System.Data.OracleClient, Version=1.0.3300.0, Culture=neutral, PublicKeyToken=b77a5c561934e089

This is an optional package that you can download from http://msdn.microsoft.com/downloads search for .NET Managed Provider for Oracle.
See Also

#### Reference

AdoNetAppender Class
log4net.Appender Namespace