Table of Contents

Class SapHanaSchemaProvider

Namespace
LinqToDB.Internal.DataProvider.SapHana
Assembly
linq2db.dll
public class SapHanaSchemaProvider : SchemaProviderBase, ISchemaProvider
Inheritance
object
SapHanaSchemaProvider
Implements
Derived
Inherited Members
Extension Methods

Properties

DefaultSchema

protected string DefaultSchema { get; }

Property Value

string

GetProcedureSchemaExecutesProcedure

If true, provider doesn't support schema-only procedure execution and will execute procedure for real.

protected override bool GetProcedureSchemaExecutesProcedure { get; }

Property Value

bool

HanaSchemaOptions

protected GetHanaSchemaOptions? HanaSchemaOptions { get; }

Property Value

GetHanaSchemaOptions

HasAccessForCalculationViews

protected bool HasAccessForCalculationViews { get; }

Property Value

bool

SchemasFilter

protected string? SchemasFilter { get; }

Property Value

string

Methods

GetColumns(DataConnection, GetSchemaOptions)

protected override List<ColumnInfo> GetColumns(DataConnection dataConnection, GetSchemaOptions options)

Parameters

dataConnection DataConnection
options GetSchemaOptions

Returns

List<ColumnInfo>

GetDataType(string?, string?, int?, int?, int?)

protected override DataType GetDataType(string? dataType, string? columnType, int? length, int? precision, int? scale)

Parameters

dataType string
columnType string
length int?
precision int?
scale int?

Returns

DataType

GetDataTypes(DataConnection)

Returns list of database data types.

protected override List<DataTypeInfo> GetDataTypes(DataConnection dataConnection)

Parameters

dataConnection DataConnection

Database connection instance.

Returns

List<DataTypeInfo>

List of database data types.

GetForeignKeys(DataConnection, IEnumerable<TableSchema>, GetSchemaOptions)

protected override IReadOnlyCollection<ForeignKeyInfo> GetForeignKeys(DataConnection dataConnection, IEnumerable<TableSchema> tables, GetSchemaOptions options)

Parameters

dataConnection DataConnection
tables IEnumerable<TableSchema>
options GetSchemaOptions

Returns

IReadOnlyCollection<ForeignKeyInfo>

GetPrimaryKeys(DataConnection, IEnumerable<TableSchema>, GetSchemaOptions)

protected override IReadOnlyCollection<PrimaryKeyInfo> GetPrimaryKeys(DataConnection dataConnection, IEnumerable<TableSchema> tables, GetSchemaOptions options)

Parameters

dataConnection DataConnection
tables IEnumerable<TableSchema>
options GetSchemaOptions

Returns

IReadOnlyCollection<PrimaryKeyInfo>

GetProcedureParameters(DataConnection, IEnumerable<ProcedureInfo>, GetSchemaOptions)

protected override List<ProcedureParameterInfo> GetProcedureParameters(DataConnection dataConnection, IEnumerable<ProcedureInfo> procedures, GetSchemaOptions options)

Parameters

dataConnection DataConnection
procedures IEnumerable<ProcedureInfo>
options GetSchemaOptions

Returns

List<ProcedureParameterInfo>

GetProcedureResultColumns(DataTable, GetSchemaOptions)

protected override List<ColumnSchema> GetProcedureResultColumns(DataTable resultTable, GetSchemaOptions options)

Parameters

resultTable DataTable
options GetSchemaOptions

Returns

List<ColumnSchema>

GetProcedures(DataConnection, GetSchemaOptions)

protected override List<ProcedureInfo>? GetProcedures(DataConnection dataConnection, GetSchemaOptions options)

Parameters

dataConnection DataConnection
options GetSchemaOptions

Returns

List<ProcedureInfo>

GetProviderSpecificTables(DataConnection, GetSchemaOptions)

protected override List<TableSchema> GetProviderSpecificTables(DataConnection dataConnection, GetSchemaOptions options)

Parameters

dataConnection DataConnection
options GetSchemaOptions

Returns

List<TableSchema>

GetProviderSpecificTypeNamespace()

protected override string? GetProviderSpecificTypeNamespace()

Returns

string

GetSchema(DataConnection, GetSchemaOptions?)

Returns database schema. Note that it is recommended to call this method outside of transaction as some providers do not support it or behave incorrectly. At least following providers shouldn't be called in transaction:

  • MySQL;
  • Microsoft SQL Server;
  • Sybase;
  • DB2.
public override DatabaseSchema GetSchema(DataConnection dataConnection, GetSchemaOptions? options = null)

Parameters

dataConnection DataConnection

Data connection to use to read schema from.

options GetSchemaOptions

Schema read configuration options.

Returns

DatabaseSchema

Returns database schema information.

GetSystemType(string?, string?, DataTypeInfo?, int?, int?, int?, GetSchemaOptions)

protected override Type? GetSystemType(string? dataType, string? columnType, DataTypeInfo? dataTypeInfo, int? length, int? precision, int? scale, GetSchemaOptions options)

Parameters

dataType string
columnType string
dataTypeInfo DataTypeInfo
length int?
precision int?
scale int?
options GetSchemaOptions

Returns

Type

GetTables(DataConnection, GetSchemaOptions)

protected override List<TableInfo> GetTables(DataConnection dataConnection, GetSchemaOptions options)

Parameters

dataConnection DataConnection
options GetSchemaOptions

Returns

List<TableInfo>

LoadProcedureTableSchema(DataConnection, GetSchemaOptions, ProcedureSchema, string, List<TableSchema>)

protected override void LoadProcedureTableSchema(DataConnection dataConnection, GetSchemaOptions options, ProcedureSchema procedure, string commandText, List<TableSchema> tables)

Parameters

dataConnection DataConnection
options GetSchemaOptions
procedure ProcedureSchema
commandText string
tables List<TableSchema>