# C1.DataConnector.AdoNet.C1ConnectionBase

## Content

<div class="doc-site-dotnet-api-container">



  <h1 id="C1_DataConnector_AdoNet_C1ConnectionBase" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase" class="text-break">C1ConnectionBase Class
</h1>
  <div class="markdown level0 summary"><p>The connection base class for all C1DataConnector.AdoNet providers</p>
</div>
  <div class="markdown level0 conceptual"></div>
  <div class="inheritance">
    <h5>Inheritance</h5>
    <div class="level0"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.object">object</a></div>
    <div class="level1"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.marshalbyrefobject">MarshalByRefObject</a></div>
    <div class="level2"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.component">Component</a></div>
    <div class="level3"><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.data.common.dbconnection">DbConnection</a></div>
    <div class="level4"><span class="xref">C1ConnectionBase</span></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
      <div class="level5"><a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase-1.html">C1ConnectionBase&lt;TConnectionImpl&gt;</a></div>
  </div>
  <div class="implements">
    <h5>Implements</h5>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.componentmodel.icomponent">IComponent</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.data.idbconnection">IDbConnection</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.idisposable">IDisposable</a></div>
    <div><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.iasyncdisposable">IAsyncDisposable</a></div>
  </div>
  <h6><strong>Namespace</strong>: <a class="xref" href="C1.DataConnector.AdoNet.html">C1.DataConnector.AdoNet</a></h6>
  <h6><strong>Assembly</strong>: C1.AdoNet.ServiceNow.dll</h6>
  <h5 id="C1_DataConnector_AdoNet_C1ConnectionBase_syntax">Syntax</h5>
  <div class="codewrapper">
    <pre><code class="lang-csharp hljs">public abstract class C1ConnectionBase : DbConnection, IComponent, IDbConnection, IDisposable, IAsyncDisposable</code></pre>
  </div>
  <div class="codewrapper">
    <pre><code class="lang-vbnet hljs">Public MustInherit Class C1ConnectionBase
    Inherits DbConnection
    Implements IComponent, IDbConnection, IDisposable, IAsyncDisposable</code></pre>
  </div>
  <h3 id="constructors">Constructors
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase__ctor_C1_DataConnector_C1ConnectionStringBuilder_Serilog_ILogger_" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.#ctor(C1.DataConnector.C1ConnectionStringBuilder,Serilog.ILogger)">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.-ctor.html#C1_DataConnector_AdoNet_C1ConnectionBase__ctor_C1_DataConnector_C1ConnectionStringBuilder_Serilog_ILogger_">C1ConnectionBase(C1ConnectionStringBuilder, ILogger)</a>
        </td>
        <td class="markdown level1 summary"><p>Initializes a C1ConnectionBase considering a connection string builder and a logger</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="properties">Properties
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_ConnectionString" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.ConnectionString">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.ConnectionString.html#C1_DataConnector_AdoNet_C1ConnectionBase_ConnectionString">ConnectionString</a>
        </td>
        <td class="markdown level1 summary"><p>Gets or sets the string used to open the connection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_ConnectionStringBuilder" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.ConnectionStringBuilder">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.ConnectionStringBuilder.html#C1_DataConnector_AdoNet_C1ConnectionBase_ConnectionStringBuilder">ConnectionStringBuilder</a>
        </td>
        <td class="markdown level1 summary"><p>Get the C1ConnectionStringBuilder used by this connection to express its connection string</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_Key" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.Key">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.Key.html#C1_DataConnector_AdoNet_C1ConnectionBase_Key">Key</a>
        </td>
        <td class="markdown level1 summary"><p>A string that identifies a unique way to connect to a server.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_Logger" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.Logger">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.Logger.html#C1_DataConnector_AdoNet_C1ConnectionBase_Logger">Logger</a>
        </td>
        <td class="markdown level1 summary"><p>The logger where the runtime messages are passed to.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_MaxPageSize" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.MaxPageSize">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.MaxPageSize.html#C1_DataConnector_AdoNet_C1ConnectionBase_MaxPageSize">MaxPageSize</a>
        </td>
        <td class="markdown level1 summary"><p>The maximum items returned per request to server</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_State" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.State">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.State.html#C1_DataConnector_AdoNet_C1ConnectionBase_State">State</a>
        </td>
        <td class="markdown level1 summary"><p>Gets a string that describes the state of the connection.</p>
</td>
      </tr>
    </tbody>
  </table>
  <h3 id="methods">Methods
</h3>
  <table class="table table-bordered table-condensed">
    <thead>
      <tr>
        <th>Name</th>
        <th>Description</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_Close" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.Close">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.Close.html#C1_DataConnector_AdoNet_C1ConnectionBase_Close">Close()</a>
        </td>
        <td class="markdown level1 summary"><p>Closes the connection to the database.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_Dispose_System_Boolean_" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.Dispose(System.Boolean)">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.Dispose.html#C1_DataConnector_AdoNet_C1ConnectionBase_Dispose_System_Boolean_">Dispose(bool)</a>
        </td>
        <td class="markdown level1 summary"><p>Disposes the resources of this connection.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetColumnsSchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetColumnsSchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetColumnsSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetColumnsSchema_System_String___">GetColumnsSchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the columns.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetDataSourceInformationSchema" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetDataSourceInformationSchema">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetDataSourceInformationSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetDataSourceInformationSchema">GetDataSourceInformationSchema()</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the dataSource informations.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetForeignKeySchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetForeignKeySchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetForeignKeySchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetForeignKeySchema_System_String___">GetForeignKeySchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the foreign keys.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetIndexColumns_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetIndexColumns(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetIndexColumns.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetIndexColumns_System_String___">GetIndexColumns(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the index columns.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetIndexesSchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetIndexesSchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetIndexesSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetIndexesSchema_System_String___">GetIndexesSchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the indexes.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetPrimaryKeySchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetPrimaryKeySchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetPrimaryKeySchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetPrimaryKeySchema_System_String___">GetPrimaryKeySchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the primary keys.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetReservedWordsSchema" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetReservedWordsSchema">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetReservedWordsSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetReservedWordsSchema">GetReservedWordsSchema()</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the reserved words.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetSchema" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetSchema">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetSchema">GetSchema()</a>
        </td>
        <td class="markdown level1 summary"><p>Returns schema information for the data source of this <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.html">C1ConnectionBase</a>.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetSchema_System_String_" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetSchema(System.String)">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetSchema_System_String_">GetSchema(string)</a>
        </td>
        <td class="markdown level1 summary"><p>Returns schema information for the data source of this <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.html">C1ConnectionBase</a> using the specified string for the schema name.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetSchema_System_String_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetSchema(System.String,System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetSchema_System_String_System_String___">GetSchema(string, string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Returns schema information for the data source of this <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.html">C1ConnectionBase</a> using the specified string
for the schema name and the specified string array for the restriction values.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetSubTableSchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetSubTableSchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetSubTableSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetSubTableSchema_System_String___">GetSubTableSchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the subtables.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetTablesSchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetTablesSchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetTablesSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetTablesSchema_System_String___">GetTablesSchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the tables.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_GetViewsSchema_System_String___" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.GetViewsSchema(System.String[])">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.GetViewsSchema.html#C1_DataConnector_AdoNet_C1ConnectionBase_GetViewsSchema_System_String___">GetViewsSchema(string[])</a>
        </td>
        <td class="markdown level1 summary"><p>Retrieve the metadata relatively to the views.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_OnConnectionStringChanged" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.OnConnectionStringChanged">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.OnConnectionStringChanged.html#C1_DataConnector_AdoNet_C1ConnectionBase_OnConnectionStringChanged">OnConnectionStringChanged()</a>
        </td>
        <td class="markdown level1 summary"><p>A method that is called every time there is a change to the connection string used by this C1.AdoNet.OData.C1ODataConnection/&gt;.</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_OpenAsync_System_Threading_CancellationToken_" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.OpenAsync(System.Threading.CancellationToken)">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.OpenAsync.html#C1_DataConnector_AdoNet_C1ConnectionBase_OpenAsync_System_Threading_CancellationToken_">OpenAsync(CancellationToken)</a>
        </td>
        <td class="markdown level1 summary"><p>An asynchronous version of C1.DataConnector.AdoNet.C1ConnectionBase.Open</p>
</td>
      </tr>
      <tr>
        <td id="C1_DataConnector_AdoNet_C1ConnectionBase_SetConnectionState_System_Data_ConnectionState_" data-uid="C1.DataConnector.AdoNet.C1ConnectionBase.SetConnectionState(System.Data.ConnectionState)">
          <a class="xref" href="../C1.AdoNet.CSV/C1.DataConnector.AdoNet.C1ConnectionBase.SetConnectionState.html#C1_DataConnector_AdoNet_C1ConnectionBase_SetConnectionState_System_Data_ConnectionState_">SetConnectionState(ConnectionState)</a>
        </td>
        <td class="markdown level1 summary"><p>If the passed state is different than the current one, it updates it and fires the StateChange event.</p>
</td>
      </tr>
    </tbody>
  </table>

</div>
