Table of Contents

Class GetSchemaOptions

Namespace
LinqToDB.SchemaProvider
Assembly
linq2db.dll

Defines schema load options.

public class GetSchemaOptions
Inheritance
GetSchemaOptions
Derived
Extension Methods

Fields

DefaultSchema

Default Schema name.

public string? DefaultSchema

Field Value

string

ExcludedCatalogs

List of disallowed databases/catalogs.

public string?[]? ExcludedCatalogs

Field Value

string[]

ExcludedSchemas

List of disallowed schemas/owners.

public string?[]? ExcludedSchemas

Field Value

string[]

GenerateChar1AsString

Should linq2db use string for char(1) type or char. Default type: char (false).

public bool GenerateChar1AsString

Field Value

bool

GetAssociationMemberName

Optional custom name generation logic for association property.

public Func<ForeignKeySchema, string>? GetAssociationMemberName

Field Value

Func<ForeignKeySchema, string>

GetForeignKeys

Enable or disable read of foreign keys. Default - enabled (true). Disabe could be useful at least for Access, as it could crash on some database files.

public bool GetForeignKeys

Field Value

bool

GetProcedures

Enable or disable read of procedures and functions metadata. Default - enabled (true).

public bool GetProcedures

Field Value

bool

GetTables

Enable or disable read of table schema. Default - enabled (true).

public bool GetTables

Field Value

bool

IgnoreSystemHistoryTables

Only for SQL Server. Doesn't return history table schema for temporal tables.

public bool IgnoreSystemHistoryTables

Field Value

bool

IncludedCatalogs

List of allowed databases/catalogs.

public string?[]? IncludedCatalogs

Field Value

string[]

IncludedSchemas

List of allowed schemas/owners.

public string?[]? IncludedSchemas

Field Value

string[]

LoadProcedure

Optional procedure metadata load filter. By default all procedures loaded.

public Func<ProcedureSchema, bool> LoadProcedure

Field Value

Func<ProcedureSchema, bool>

LoadTable

Optinal callback to filter loaded tables. receives object with table details and return boolean flag to indicate that table should be loaded (true) or skipped (false).

public Func<LoadTableData, bool>? LoadTable

Field Value

Func<LoadTableData, bool>

PreferProviderSpecificTypes

When set to true, will prefer generation of provider-specific types instead of general types.

public bool PreferProviderSpecificTypes

Field Value

bool

ProcedureLoadingProgress

Optional callback to report procedure metadata load progress. First parameter contains total number of discovered procedures. Second parameter provides position of currently loaded procedure.

public Action<int, int> ProcedureLoadingProgress

Field Value

Action<int, int>

StringComparer

String comparison logic for IncludedSchemas, ExcludedSchemas, IncludedCatalogs and ExcludedCatalogs values. Default is OrdinalIgnoreCase.

public StringComparer StringComparer

Field Value

StringComparer

UseSchemaOnly

if set to true, SchemaProvider uses SchemaOnly to get SqlServer metadata. Otherwise the sp_describe_first_result_set sproc is used.

public bool UseSchemaOnly

Field Value

bool