Table of Contents

Interface ISqlOptimizer

Namespace
LinqToDB.SqlProvider
Assembly
linq2db.dll
public interface ISqlOptimizer
Extension Methods

Methods

ConvertElement(MappingSchema, DataOptions, IQueryElement?, OptimizationContext)

Converts query element to specific provider dialect.

IQueryElement? ConvertElement(MappingSchema mappingSchema, DataOptions dataOptions, IQueryElement? element, OptimizationContext context)

Parameters

mappingSchema MappingSchema
dataOptions DataOptions
element IQueryElement
context OptimizationContext

Returns

IQueryElement

ConvertSkipTake(MappingSchema, DataOptions, SelectQuery, OptimizationContext, out ISqlExpression?, out ISqlExpression?)

Corrects skip/take for specific DataProvider

void ConvertSkipTake(MappingSchema mappingSchema, DataOptions dataOptions, SelectQuery selectQuery, OptimizationContext optimizationContext, out ISqlExpression? takeExpr, out ISqlExpression? skipExpr)

Parameters

mappingSchema MappingSchema
dataOptions DataOptions
selectQuery SelectQuery
optimizationContext OptimizationContext
takeExpr ISqlExpression
skipExpr ISqlExpression

Finalize(MappingSchema, SqlStatement, DataOptions)

Finalizes query.

SqlStatement Finalize(MappingSchema mappingSchema, SqlStatement statement, DataOptions dataOptions)

Parameters

mappingSchema MappingSchema
statement SqlStatement
dataOptions DataOptions

Returns

SqlStatement

Query which is ready for optimization.

IsParameterDependent(SqlStatement)

Examine query for parameter dependency.

bool IsParameterDependent(SqlStatement statement)

Parameters

statement SqlStatement

Returns

bool