
# IDatabaseLibDocument interface

The `IDatabaseLibDocument` interface represents a database library document.

```csharp
public interface IDatabaseLibDocument
```

**Namespace:** EDP · **Assembly:** Altium.SDK.Interfaces

**Derived:** [ISVNDatabaseLibDocument](https://altiumdeveloper.github.io/ad-sdk-docs/reference/edp/ISVNDatabaseLibDocument.md)

## Properties

| Property | Type | Access | Description |
| --- | --- | --- | --- |
| [ConnectionString](#connectionstring) | `string` | get; set |  |

### ConnectionString

*No description yet.*

```csharp
string GetConnectionString();
void SetConnectionString(string argConnectionString);
```

**Type:** `string` · **Access:** read/write

## Methods

| Method | Returns | Description |
| --- | --- | --- |
| [ClearDatabaseTypeFields](#cleardatabasetypefields) | `void` |  |
| [CreateTableInDatabase](#createtableindatabase) | `void` |  |
| [DisposeIfNotShowing](#disposeifnotshowing) | `void` |  |
| [ExportNewRecordFromIntLib](#exportnewrecordfromintlib) | `string` |  |
| [FinaliseExportFromDatabase](#finaliseexportfromdatabase) | `void` |  |
| [GetAllComponentKeys](#getallcomponentkeys) | `void` |  |
| [GetCommandString](#getcommandstring) | `string` |  |
| [GetDatafilePath](#getdatafilepath) | `string` |  |
| [GetFieldCount](#getfieldcount) | `int` |  |
| [GetFieldNameAt](#getfieldnameat) | `string` |  |
| [GetFileName](#getfilename) | `string` |  |
| [GetFilterText](#getfiltertext) | `string` |  |
| [GetItemCount](#getitemcount) | `int` |  |
| [GetKeyField](#getkeyfield) | `string` |  |
| [GetKeyFieldCount](#getkeyfieldcount) | `int` |  |
| [GetLibraryPathFieldName](#getlibrarypathfieldname) | `string` |  |
| [GetLibraryRefFieldName](#getlibraryreffieldname) | `string` |  |
| [GetLibrarySearchPath](#getlibrarysearchpath) | `string` |  |
| [GetModelFieldNamesAt](#getmodelfieldnamesat) | `void` |  |
| [GetOrcadLibraryDetails](#getorcadlibrarydetails) | `void` |  |
| [GetParameterNameAt](#getparameternameat) | `string` |  |
| [GetParametersForComponent](#getparametersforcomponent) | `string` |  |
| [GetSchLibPathForComponent](#getschlibpathforcomponent) | `string` |  |
| [GetSchLibRefForComponent](#getschlibrefforcomponent) | `string` |  |
| [GetSearchSubDirectories](#getsearchsubdirectories) | `bool` |  |
| [GetTableCount](#gettablecount) | `int` |  |
| [GetTableIndex](#gettableindex) | `int` |  |
| [GetTableNameAt](#gettablenameat) | `string` |  |
| [InitialiseExportFromIntLib](#initialiseexportfromintlib) | `string` |  |
| [InitialiseExportToDatabase](#initialiseexporttodatabase) | `void` |  |
| [IsParameterDatabaseKey](#isparameterdatabasekey) | `bool` |  |
| [IsValidSQLStatementForTable](#isvalidsqlstatementfortable) | `bool` |  |
| [LoadAllRecordsLimit](#loadallrecordslimit) | `int` |  |
| [OrcadDelimiter](#orcaddelimiter) | `char` |  |
| [TableContainsColumn](#tablecontainscolumn) | `bool` |  |
| [TableEnabled](#tableenabled) | `bool` |  |
| [ValidateSQLQuery](#validatesqlquery) | `string` |  |

### ClearDatabaseTypeFields

*No description yet.*

```csharp
void ClearDatabaseTypeFields();
```

**Returns:** nothing (`void`)

### CreateTableInDatabase

*No description yet.*

```csharp
void CreateTableInDatabase(string argTableName, string argPrimaryKeyColumnName);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableName` | `string` | value |
| `argPrimaryKeyColumnName` | `string` | value |

**Returns:** nothing (`void`)

### DisposeIfNotShowing

*No description yet.*

```csharp
void DisposeIfNotShowing();
```

**Returns:** nothing (`void`)

### ExportNewRecordFromIntLib

*No description yet.*

```csharp
string ExportNewRecordFromIntLib(string argTableName, string argFieldParameters);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableName` | `string` | value |
| `argFieldParameters` | `string` | value |

**Returns:** `string`

### FinaliseExportFromDatabase

*No description yet.*

```csharp
void FinaliseExportFromDatabase();
```

**Returns:** nothing (`void`)

### GetAllComponentKeys

*No description yet.*

```csharp
void GetAllComponentKeys(int argTableIndex, IStrings argResults);
void GetAllComponentKeys(int argTableIndex, object argResults);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argResults` | [IStrings](https://altiumdeveloper.github.io/ad-sdk-docs/reference/dxp/IStrings.md) | value |

**Returns:** nothing (`void`)

The first overload is an extension method of `IDatabaseLibDocumentHelper` (`using EDP;`) with typed parameters; the second is declared by the interface.

### GetCommandString

*No description yet.*

```csharp
string GetCommandString(int argTableIndex, string argFilterText, string argSQLWhereClause);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argFilterText` | `string` | value |
| `argSQLWhereClause` | `string` | value |

**Returns:** `string`

### GetDatafilePath

*No description yet.*

```csharp
string GetDatafilePath(string argName, string argType, string argTableName, string argComponentKeys);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argName` | `string` | value |
| `argType` | `string` | value |
| `argTableName` | `string` | value |
| `argComponentKeys` | `string` | value |

**Returns:** `string`

### GetFieldCount

*No description yet.*

```csharp
int GetFieldCount(int argTableIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |

**Returns:** `int`

### GetFieldNameAt

*No description yet.*

```csharp
string GetFieldNameAt(int argTableIndex, int argFieldIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argFieldIndex` | `int` | value |

**Returns:** `string`

### GetFileName

*No description yet.*

```csharp
string GetFileName();
```

**Returns:** `string`

### GetFilterText

*No description yet.*

```csharp
string GetFilterText(int argTableIndex, string argFilterColumnNames, string argFilterValue);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argFilterColumnNames` | `string` | value |
| `argFilterValue` | `string` | value |

**Returns:** `string`

### GetItemCount

*No description yet.*

```csharp
int GetItemCount(string argCommand, ref string argnError);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argCommand` | `string` | value |
| `argnError` | `string` | ref |

**Returns:** `int`

### GetKeyField

*No description yet.*

```csharp
string GetKeyField(bool argParameterName, int argTableIndex, int argKeyIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argParameterName` | `bool` | value |
| `argTableIndex` | `int` | value |
| `argKeyIndex` | `int` | value |

**Returns:** `string`

### GetKeyFieldCount

*No description yet.*

```csharp
int GetKeyFieldCount(int argTableIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |

**Returns:** `int`

### GetLibraryPathFieldName

*No description yet.*

```csharp
string GetLibraryPathFieldName(int argTableIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |

**Returns:** `string`

### GetLibraryRefFieldName

*No description yet.*

```csharp
string GetLibraryRefFieldName(int argTableIndex, ref bool argOrcadLibrary);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argOrcadLibrary` | `bool` | ref |

**Returns:** `string`

### GetLibrarySearchPath

*No description yet.*

```csharp
string GetLibrarySearchPath();
```

**Returns:** `string`

### GetModelFieldNamesAt

*No description yet.*

```csharp
void GetModelFieldNamesAt(int argnIndex, int argTableIndex, string argModelType, ref string argModelPathName, ref string argModelRefName, ref bool argOrcadModel);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argnIndex` | `int` | value |
| `argTableIndex` | `int` | value |
| `argModelType` | `string` | value |
| `argModelPathName` | `string` | ref |
| `argModelRefName` | `string` | ref |
| `argOrcadModel` | `bool` | ref |

**Returns:** nothing (`void`)

### GetOrcadLibraryDetails

*No description yet.*

```csharp
void GetOrcadLibraryDetails(string argParseString, ref string argLibRef, ref string argLibPath);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argParseString` | `string` | value |
| `argLibRef` | `string` | ref |
| `argLibPath` | `string` | ref |

**Returns:** nothing (`void`)

### GetParameterNameAt

*No description yet.*

```csharp
string GetParameterNameAt(int argTableIndex, int argFieldIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argFieldIndex` | `int` | value |

**Returns:** `string`

### GetParametersForComponent

*No description yet.*

```csharp
string GetParametersForComponent(int argTableIndex, string argComponentKeys);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argComponentKeys` | `string` | value |

**Returns:** `string`

### GetSchLibPathForComponent

*No description yet.*

```csharp
string GetSchLibPathForComponent(int argTableIndex, string argComponentKeys);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argComponentKeys` | `string` | value |

**Returns:** `string`

### GetSchLibRefForComponent

*No description yet.*

```csharp
string GetSchLibRefForComponent(int argTableIndex, string argComponentKeys);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argComponentKeys` | `string` | value |

**Returns:** `string`

### GetSearchSubDirectories

*No description yet.*

```csharp
bool GetSearchSubDirectories();
```

**Returns:** `bool`

### GetTableCount

*No description yet.*

```csharp
int GetTableCount();
```

**Returns:** `int`

### GetTableIndex

*No description yet.*

```csharp
int GetTableIndex(string argTableName);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableName` | `string` | value |

**Returns:** `int`

### GetTableNameAt

*No description yet.*

```csharp
string GetTableNameAt(int argnIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argnIndex` | `int` | value |

**Returns:** `string`

### InitialiseExportFromIntLib

*No description yet.*

```csharp
string InitialiseExportFromIntLib(string argTableName);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableName` | `string` | value |

**Returns:** `string`

### InitialiseExportToDatabase

*No description yet.*

```csharp
void InitialiseExportToDatabase(string argDatabaseFileName);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argDatabaseFileName` | `string` | value |

**Returns:** nothing (`void`)

### IsParameterDatabaseKey

*No description yet.*

```csharp
bool IsParameterDatabaseKey(int argTableIndex, string argParameterName);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argParameterName` | `string` | value |

**Returns:** `bool`

### IsValidSQLStatementForTable

*No description yet.*

```csharp
bool IsValidSQLStatementForTable(string argTableName, string argQuery);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableName` | `string` | value |
| `argQuery` | `string` | value |

**Returns:** `bool`

### LoadAllRecordsLimit

*No description yet.*

```csharp
int LoadAllRecordsLimit();
```

**Returns:** `int`

### OrcadDelimiter

*No description yet.*

```csharp
char OrcadDelimiter();
```

**Returns:** `char`

### TableContainsColumn

*No description yet.*

```csharp
bool TableContainsColumn(int argTableIndex, string argColumnName);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argTableIndex` | `int` | value |
| `argColumnName` | `string` | value |

**Returns:** `bool`

### TableEnabled

*No description yet.*

```csharp
bool TableEnabled(int argnIndex);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argnIndex` | `int` | value |

**Returns:** `bool`

### ValidateSQLQuery

*No description yet.*

```csharp
string ValidateSQLQuery(string argSqlQuery);
```

| Parameter | Type | Passing |
| --- | --- | --- |
| `argSqlQuery` | `string` | value |

**Returns:** `string`

## Returned by

[IIntegratedLibraryManager.GetAvailableDBLibDocAtPath](https://altiumdeveloper.github.io/ad-sdk-docs/reference/sch/IIntegratedLibraryManager.md#getavailabledblibdocatpath)

## Accepted by

[IIntegratedLibraryManager.ExtractSourcesToDatabaseLib](https://altiumdeveloper.github.io/ad-sdk-docs/reference/sch/IIntegratedLibraryManager.md#extractsourcestodatabaselib)
