Table of Contents

Class BasicSqlOptimizer

Namespace
LinqToDB.SqlProvider
Assembly
linq2db.dll
public class BasicSqlOptimizer : ISqlOptimizer
Inheritance
BasicSqlOptimizer
Implements
Derived
Extension Methods

Constructors

BasicSqlOptimizer(SqlProviderFlags)

protected BasicSqlOptimizer(SqlProviderFlags sqlProviderFlags)

Parameters

sqlProviderFlags SqlProviderFlags

Fields

StandardLikeCharactersToEscape

protected static string[] StandardLikeCharactersToEscape

Field Value

string[]

Properties

CanCompareSearchConditions

public virtual bool CanCompareSearchConditions { get; }

Property Value

bool

LikeCharactersToEscape

Characters with special meaning in LIKE predicate (defined by LikeCharactersToEscape) that should be escaped to be used as matched character. Default: ["%", "_", "?", "*", "#", "[", "]"].

public virtual string[] LikeCharactersToEscape { get; }

Property Value

string[]

LikeEscapeCharacter

Escape sequence/character to escape special characters in LIKE predicate (defined by LikeCharactersToEscape). Default: "~".

public virtual string LikeEscapeCharacter { get; }

Property Value

string

LikeIsEscapeSupported

Should be true for provider with LIKE ... ESCAPE modifier support. Default: true.

public virtual bool LikeIsEscapeSupported { get; }

Property Value

bool

LikePatternParameterSupport

public virtual bool LikePatternParameterSupport { get; }

Property Value

bool

LikeValueParameterSupport

public virtual bool LikeValueParameterSupport { get; }

Property Value

bool

LikeWildcardCharacter

public virtual string LikeWildcardCharacter { get; }

Property Value

string

SqlProviderFlags

public SqlProviderFlags SqlProviderFlags { get; }

Property Value

SqlProviderFlags

Methods

Add(ISqlExpression, ISqlExpression, Type)

public ISqlExpression Add(ISqlExpression expr1, ISqlExpression expr2, Type type)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression
type Type

Returns

ISqlExpression

Add(ISqlExpression, int)

public ISqlExpression Add(ISqlExpression expr1, int value)

Parameters

expr1 ISqlExpression
value int

Returns

ISqlExpression

Add<T>(ISqlExpression, ISqlExpression)

public ISqlExpression Add<T>(ISqlExpression expr1, ISqlExpression expr2)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression

Returns

ISqlExpression

Type Parameters

T

AlternativeConvertToBoolean(SqlFunction, DataOptions, int)

protected ISqlExpression? AlternativeConvertToBoolean(SqlFunction func, DataOptions dataOptions, int paramNumber)

Parameters

func SqlFunction
dataOptions DataOptions
paramNumber int

Returns

ISqlExpression

CheckAliases(SqlStatement, int)

protected void CheckAliases(SqlStatement statement, int maxLen)

Parameters

statement SqlStatement
maxLen int

ConvertBetweenPredicate(Between)

public virtual ISqlPredicate ConvertBetweenPredicate(SqlPredicate.Between between)

Parameters

between SqlPredicate.Between

Returns

ISqlPredicate

ConvertBooleanExprToCase(ISqlExpression)

protected ISqlExpression ConvertBooleanExprToCase(ISqlExpression expression)

Parameters

expression ISqlExpression

Returns

ISqlExpression

ConvertCoalesceToBinaryFunc(SqlFunction, string, bool)

protected ISqlExpression ConvertCoalesceToBinaryFunc(SqlFunction func, string funcName, bool supportsParameters = true)

Parameters

func SqlFunction
funcName string
supportsParameters bool

Returns

ISqlExpression

ConvertConversion(SqlFunction)

Implements CONVERT function converter.

protected virtual ISqlExpression ConvertConversion(SqlFunction func)

Parameters

func SqlFunction

Returns

ISqlExpression

ConvertCountSubQuery(SelectQuery)

public virtual bool ConvertCountSubQuery(SelectQuery subQuery)

Parameters

subQuery SelectQuery

Returns

bool

ConvertElement(MappingSchema, DataOptions, IQueryElement?, OptimizationContext)

Converts query element to specific provider dialect.

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

Parameters

mappingSchema MappingSchema
dataOptions DataOptions
element IQueryElement
context OptimizationContext

Returns

IQueryElement

ConvertExpressionImpl(ISqlExpression, ConvertVisitor<RunOptimizationContext>)

public virtual ISqlExpression ConvertExpressionImpl(ISqlExpression expression, ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext> visitor)

Parameters

expression ISqlExpression
visitor ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext>

Returns

ISqlExpression

ConvertFunction(SqlFunction)

protected virtual ISqlExpression ConvertFunction(SqlFunction func)

Parameters

func SqlFunction

Returns

ISqlExpression

ConvertFunctionParameters(SqlFunction, bool)

protected SqlFunction ConvertFunctionParameters(SqlFunction func, bool withParameters = false)

Parameters

func SqlFunction
withParameters bool

Returns

SqlFunction

ConvertInListPredicate(MappingSchema, InList, EvaluationContext)

public virtual ISqlPredicate ConvertInListPredicate(MappingSchema mappingSchema, SqlPredicate.InList p, EvaluationContext context)

Parameters

mappingSchema MappingSchema
p SqlPredicate.InList
context EvaluationContext

Returns

ISqlPredicate

ConvertLikePredicate(MappingSchema, Like, EvaluationContext)

LIKE predicate interceptor. Default implementation does nothing.

public virtual ISqlPredicate ConvertLikePredicate(MappingSchema mappingSchema, SqlPredicate.Like predicate, EvaluationContext context)

Parameters

mappingSchema MappingSchema

Current mapping schema.

predicate SqlPredicate.Like

LIKE predicate.

context EvaluationContext

Parameters evaluation context for current query.

Returns

ISqlPredicate

Preprocessed predicate.

ConvertPredicateImpl(ISqlPredicate, ConvertVisitor<RunOptimizationContext>)

public virtual ISqlPredicate ConvertPredicateImpl(ISqlPredicate predicate, ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext> visitor)

Parameters

predicate ISqlPredicate
visitor ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext>

Returns

ISqlPredicate

ConvertSearchStringPredicate(SearchString, ConvertVisitor<RunOptimizationContext>)

public virtual ISqlPredicate ConvertSearchStringPredicate(SqlPredicate.SearchString predicate, ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext> visitor)

Parameters

predicate SqlPredicate.SearchString
visitor ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext>

Returns

ISqlPredicate

ConvertSearchStringPredicateViaLike(SearchString, ConvertVisitor<RunOptimizationContext>)

protected ISqlPredicate ConvertSearchStringPredicateViaLike(SqlPredicate.SearchString predicate, ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext> visitor)

Parameters

predicate SqlPredicate.SearchString
visitor ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext>

Returns

ISqlPredicate

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

Corrects skip/take for specific DataProvider

public virtual 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

CorrectUnionOrderBy(SqlStatement)

protected virtual SqlStatement CorrectUnionOrderBy(SqlStatement statement)

Parameters

statement SqlStatement

Returns

SqlStatement

CorrectUpdateTable(SqlUpdateStatement)

Corrects situation when update table is located in JOIN clause. Usually it is generated by associations.

protected SqlUpdateStatement CorrectUpdateTable(SqlUpdateStatement statement)

Parameters

statement SqlUpdateStatement

Statement to examine.

Returns

SqlUpdateStatement

Corrected statement.

CreateSqlValue(object?, DbDataType, params ISqlExpression[])

public static ISqlExpression CreateSqlValue(object? value, DbDataType dbDataType, params ISqlExpression[] basedOn)

Parameters

value object
dbDataType DbDataType
basedOn ISqlExpression[]

Returns

ISqlExpression

CreateSqlValue(object?, SqlBinaryExpression)

public static ISqlExpression CreateSqlValue(object? value, SqlBinaryExpression be)

Parameters

value object
be SqlBinaryExpression

Returns

ISqlExpression

Dec(ISqlExpression)

public ISqlExpression Dec(ISqlExpression expr1)

Parameters

expr1 ISqlExpression

Returns

ISqlExpression

Div(ISqlExpression, ISqlExpression, Type)

public ISqlExpression Div(ISqlExpression expr1, ISqlExpression expr2, Type type)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression
type Type

Returns

ISqlExpression

Div(ISqlExpression, int)

public ISqlExpression Div(ISqlExpression expr1, int value)

Parameters

expr1 ISqlExpression
value int

Returns

ISqlExpression

Div<T>(ISqlExpression, ISqlExpression)

public ISqlExpression Div<T>(ISqlExpression expr1, ISqlExpression expr2)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression

Returns

ISqlExpression

Type Parameters

T

EscapeLikeCharacters(ISqlExpression, ref ISqlExpression?)

public virtual ISqlExpression EscapeLikeCharacters(ISqlExpression expression, ref ISqlExpression? escape)

Parameters

expression ISqlExpression
escape ISqlExpression

Returns

ISqlExpression

EscapeLikeCharacters(string, string)

public virtual string EscapeLikeCharacters(string str, string escape)

Parameters

str string
escape string

Returns

string

EscapeLikePattern(string)

Implements LIKE pattern escaping logic for provider without ESCAPE clause support (LikeIsEscapeSupported is false). Default logic prefix characters from LikeCharactersToEscape with LikeEscapeCharacter.

protected virtual string EscapeLikePattern(string str)

Parameters

str string

Raw pattern value.

Returns

string

Escaped pattern value.

Finalize(MappingSchema, SqlStatement, DataOptions)

Finalizes query.

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

Parameters

mappingSchema MappingSchema
statement SqlStatement
dataOptions DataOptions

Returns

SqlStatement

Query which is ready for optimization.

FinalizeStatement(SqlStatement, EvaluationContext, DataOptions)

public virtual SqlStatement FinalizeStatement(SqlStatement statement, EvaluationContext context, DataOptions dataOptions)

Parameters

statement SqlStatement
context EvaluationContext
dataOptions DataOptions

Returns

SqlStatement

FindUpdateTable(SelectQuery, SqlTable)

protected SqlTable? FindUpdateTable(SelectQuery selectQuery, SqlTable tableToFind)

Parameters

selectQuery SelectQuery
tableToFind SqlTable

Returns

SqlTable

FixEmptySelect(SqlStatement)

protected virtual void FixEmptySelect(SqlStatement statement)

Parameters

statement SqlStatement

FixSetOperationNulls(SqlStatement)

protected virtual SqlStatement FixSetOperationNulls(SqlStatement statement)

Parameters

statement SqlStatement

Returns

SqlStatement

FloorBeforeConvert(SqlFunction)

protected ISqlExpression FloorBeforeConvert(SqlFunction func)

Parameters

func SqlFunction

Returns

ISqlExpression

GenerateEscapeReplacement(ISqlExpression, ISqlExpression)

public static ISqlExpression GenerateEscapeReplacement(ISqlExpression expression, ISqlExpression character)

Parameters

expression ISqlExpression
character ISqlExpression

Returns

ISqlExpression

GetAlternativeDelete(SqlDeleteStatement, DataOptions)

protected SqlDeleteStatement GetAlternativeDelete(SqlDeleteStatement deleteStatement, DataOptions dataOptions)

Parameters

deleteStatement SqlDeleteStatement
dataOptions DataOptions

Returns

SqlDeleteStatement

GetAlternativeUpdate(SqlUpdateStatement, DataOptions)

protected SqlUpdateStatement GetAlternativeUpdate(SqlUpdateStatement updateStatement, DataOptions dataOptions)

Parameters

updateStatement SqlUpdateStatement
dataOptions DataOptions

Returns

SqlUpdateStatement

GetAlternativeUpdatePostgreSqlite(SqlUpdateStatement, DataOptions)

protected SqlStatement GetAlternativeUpdatePostgreSqlite(SqlUpdateStatement statement, DataOptions dataOptions)

Parameters

statement SqlUpdateStatement
dataOptions DataOptions

Returns

SqlStatement

GetMainTableSource(SelectQuery)

protected SqlTableSource? GetMainTableSource(SelectQuery selectQuery)

Parameters

selectQuery SelectQuery

Returns

SqlTableSource

GetMaxDisplaySize(SqlDataType)

protected virtual int? GetMaxDisplaySize(SqlDataType type)

Parameters

type SqlDataType

Returns

int?

GetMaxLength(SqlDataType)

protected virtual int? GetMaxLength(SqlDataType type)

Parameters

type SqlDataType

Returns

int?

GetMaxPrecision(SqlDataType)

protected virtual int? GetMaxPrecision(SqlDataType type)

Parameters

type SqlDataType

Returns

int?

GetMaxScale(SqlDataType)

protected virtual int? GetMaxScale(SqlDataType type)

Parameters

type SqlDataType

Returns

int?

HasParameters(ISqlExpression)

protected static bool HasParameters(ISqlExpression expr)

Parameters

expr ISqlExpression

Returns

bool

Inc(ISqlExpression)

public ISqlExpression Inc(ISqlExpression expr1)

Parameters

expr1 ISqlExpression

Returns

ISqlExpression

IsAggregationFunction(IQueryElement)

public static bool IsAggregationFunction(IQueryElement expr)

Parameters

expr IQueryElement

Returns

bool

IsBooleanParameter(ISqlExpression, int, int)

protected static bool IsBooleanParameter(ISqlExpression expr, int count, int i)

Parameters

expr ISqlExpression
count int
i int

Returns

bool

IsDateDataOffsetType(ISqlExpression)

protected static bool IsDateDataOffsetType(ISqlExpression expr)

Parameters

expr ISqlExpression

Returns

bool

IsDateDataType(ISqlExpression, string)

protected static bool IsDateDataType(ISqlExpression expr, string dateName)

Parameters

expr ISqlExpression
dateName string

Returns

bool

IsDateTime2Type(ISqlExpression, string)

protected static bool IsDateTime2Type(ISqlExpression expr, string typeName)

Parameters

expr ISqlExpression
typeName string

Returns

bool

IsDateTimeType(ISqlExpression, string)

protected static bool IsDateTimeType(ISqlExpression expr, string typeName)

Parameters

expr ISqlExpression
typeName string

Returns

bool

IsParameterDependedElement(IQueryElement)

public virtual bool IsParameterDependedElement(IQueryElement element)

Parameters

element IQueryElement

Returns

bool

IsParameterDependedQuery(SelectQuery)

public virtual bool IsParameterDependedQuery(SelectQuery query)

Parameters

query SelectQuery

Returns

bool

IsParameterDependent(SqlStatement)

Examine query for parameter dependency.

public bool IsParameterDependent(SqlStatement statement)

Parameters

statement SqlStatement

Returns

bool

IsSmallDateTimeType(ISqlExpression, string)

protected static bool IsSmallDateTimeType(ISqlExpression expr, string typeName)

Parameters

expr ISqlExpression
typeName string

Returns

bool

IsTimeDataType(ISqlExpression)

protected static bool IsTimeDataType(ISqlExpression expr)

Parameters

expr ISqlExpression

Returns

bool

Mul(ISqlExpression, ISqlExpression, Type)

public ISqlExpression Mul(ISqlExpression expr1, ISqlExpression expr2, Type type)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression
type Type

Returns

ISqlExpression

Mul(ISqlExpression, int)

public ISqlExpression Mul(ISqlExpression expr1, int value)

Parameters

expr1 ISqlExpression
value int

Returns

ISqlExpression

Mul<T>(ISqlExpression, ISqlExpression)

public ISqlExpression Mul<T>(ISqlExpression expr1, ISqlExpression expr2)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression

Returns

ISqlExpression

Type Parameters

T

NeedsEnvelopingForUpdate(SelectQuery)

protected bool NeedsEnvelopingForUpdate(SelectQuery query)

Parameters

query SelectQuery

Returns

bool

OptimizeAggregates(SqlStatement)

public SqlStatement OptimizeAggregates(SqlStatement statement)

Parameters

statement SqlStatement

Returns

SqlStatement

OptimizeBinaryExpression(SqlBinaryExpression, EvaluationContext)

public virtual ISqlExpression OptimizeBinaryExpression(SqlBinaryExpression be, EvaluationContext context)

Parameters

be SqlBinaryExpression
context EvaluationContext

Returns

ISqlExpression

OptimizeElement(MappingSchema, DataOptions, IQueryElement?, OptimizationContext, bool)

public IQueryElement? OptimizeElement(MappingSchema mappingSchema, DataOptions dataOptions, IQueryElement? element, OptimizationContext optimizationContext, bool withConversion)

Parameters

mappingSchema MappingSchema
dataOptions DataOptions
element IQueryElement
optimizationContext OptimizationContext
withConversion bool

Returns

IQueryElement

OptimizeExpression(ISqlExpression, ConvertVisitor<RunOptimizationContext>)

public virtual ISqlExpression OptimizeExpression(ISqlExpression expression, ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext> convertVisitor)

Parameters

expression ISqlExpression
convertVisitor ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext>

Returns

ISqlExpression

OptimizeFunction(SqlFunction, EvaluationContext)

public virtual ISqlExpression OptimizeFunction(SqlFunction func, EvaluationContext context)

Parameters

func SqlFunction
context EvaluationContext

Returns

ISqlExpression

OptimizeJoins(SqlStatement)

public void OptimizeJoins(SqlStatement statement)

Parameters

statement SqlStatement

OptimizePredicate(ISqlPredicate, EvaluationContext, DataOptions)

public virtual ISqlPredicate OptimizePredicate(ISqlPredicate predicate, EvaluationContext context, DataOptions dataOptions)

Parameters

predicate ISqlPredicate
context EvaluationContext
dataOptions DataOptions

Returns

ISqlPredicate

OptimizeQueryElement(ConvertVisitor<RunOptimizationContext>, IQueryElement)

public virtual IQueryElement OptimizeQueryElement(ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext> visitor, IQueryElement element)

Parameters

visitor ConvertVisitor<BasicSqlOptimizer.RunOptimizationContext>
element IQueryElement

Returns

IQueryElement

OptimizeRowExprExpr(ExprExpr, EvaluationContext)

protected ISqlPredicate OptimizeRowExprExpr(SqlPredicate.ExprExpr predicate, EvaluationContext context)

Parameters

predicate SqlPredicate.ExprExpr
context EvaluationContext

Returns

ISqlPredicate

OptimizeRowInList(InList)

protected virtual ISqlPredicate OptimizeRowInList(SqlPredicate.InList predicate)

Parameters

predicate SqlPredicate.InList

Returns

ISqlPredicate

OptimizeUpdateSubqueries(SqlStatement, DataOptions)

protected virtual SqlStatement OptimizeUpdateSubqueries(SqlStatement statement, DataOptions dataOptions)

Parameters

statement SqlStatement
dataOptions DataOptions

Returns

SqlStatement

ReplaceDistinctOrderByWithRowNumber(SqlStatement, Func<SelectQuery, bool>)

Alternative mechanism how to prevent loosing sorting in Distinct queries.

protected SqlStatement ReplaceDistinctOrderByWithRowNumber(SqlStatement statement, Func<SelectQuery, bool> queryFilter)

Parameters

statement SqlStatement

Statement which may contain Distinct queries.

queryFilter Func<SelectQuery, bool>

Query filter predicate to determine if query needs processing.

Returns

SqlStatement

The same statement or modified statement when transformation has been performed.

ReplaceTakeSkipWithRowNumber(SqlStatement, bool, bool)

Replaces pagination by Window function ROW_NUMBER().

protected SqlStatement ReplaceTakeSkipWithRowNumber(SqlStatement statement, bool supportsEmptyOrderBy, bool onlySubqueries)

Parameters

statement SqlStatement

Statement which may contain take/skip modifiers.

supportsEmptyOrderBy bool

Indicates that database supports OVER () syntax.

onlySubqueries bool

Indicates when transformation needed only for subqueries.

Returns

SqlStatement

The same statement or modified statement when transformation has been performed.

ReplaceTakeSkipWithRowNumber<TContext>(TContext, SqlStatement, Func<TContext, SelectQuery, bool>, bool)

Replaces pagination by Window function ROW_NUMBER().

protected SqlStatement ReplaceTakeSkipWithRowNumber<TContext>(TContext context, SqlStatement statement, Func<TContext, SelectQuery, bool> predicate, bool supportsEmptyOrderBy)

Parameters

context TContext

predicate context object.

statement SqlStatement

Statement which may contain take/skip modifiers.

predicate Func<TContext, SelectQuery, bool>

Indicates when the transformation is needed

supportsEmptyOrderBy bool

Indicates that database supports OVER () syntax.

Returns

SqlStatement

The same statement or modified statement when transformation has been performed.

Type Parameters

TContext

RowComparisonFallback(Operator, SqlRow, SqlRow, EvaluationContext)

protected ISqlPredicate RowComparisonFallback(SqlPredicate.Operator op, SqlRow row1, SqlRow row2, EvaluationContext context)

Parameters

op SqlPredicate.Operator
row1 SqlRow
row2 SqlRow
context EvaluationContext

Returns

ISqlPredicate

RowIsNullFallback(SqlRow, bool)

protected ISqlPredicate RowIsNullFallback(SqlRow row, bool isNot)

Parameters

row SqlRow
isNot bool

Returns

ISqlPredicate

SeparateDistinctFromPagination(SqlStatement, Func<SelectQuery, bool>)

Moves Distinct query into another subquery. Useful when preserving ordering is required, because some providers do not support DISTINCT ORDER BY.

-- before
SELECT DISTINCT TAKE 10 c1, c2
FROM A
ORDER BY c1
-- after
SELECT TAKE 10 B.c1, B.c2
FROM
  (
    SELECT DISTINCT c1, c2
    FROM A
  ) B
ORDER BY B.c1
protected SqlStatement SeparateDistinctFromPagination(SqlStatement statement, Func<SelectQuery, bool> queryFilter)

Parameters

statement SqlStatement

Statement which may contain take/skip and Distinct modifiers.

queryFilter Func<SelectQuery, bool>

Query filter predicate to determine if query needs processing.

Returns

SqlStatement

The same statement or modified statement when transformation has been performed.

Sub(ISqlExpression, ISqlExpression, Type)

public ISqlExpression Sub(ISqlExpression expr1, ISqlExpression expr2, Type type)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression
type Type

Returns

ISqlExpression

Sub(ISqlExpression, int)

public ISqlExpression Sub(ISqlExpression expr1, int value)

Parameters

expr1 ISqlExpression
value int

Returns

ISqlExpression

Sub<T>(ISqlExpression, ISqlExpression)

public ISqlExpression Sub<T>(ISqlExpression expr1, ISqlExpression expr2)

Parameters

expr1 ISqlExpression
expr2 ISqlExpression

Returns

ISqlExpression

Type Parameters

T

TransformStatement(SqlStatement, DataOptions)

Used for correcting statement and should return new statement if changes were made.

public virtual SqlStatement TransformStatement(SqlStatement statement, DataOptions dataOptions)

Parameters

statement SqlStatement
dataOptions DataOptions

Returns

SqlStatement

TryConvertToValue(ISqlExpression, EvaluationContext)

protected static ISqlExpression TryConvertToValue(ISqlExpression expr, EvaluationContext context)

Parameters

expr ISqlExpression
context EvaluationContext

Returns

ISqlExpression