Class SqlStatement
public abstract class SqlStatement : IQueryElement, ISqlExpressionWalkable
- Inheritance
-
SqlStatement
- Implements
- Derived
- Extension Methods
Properties
DebugSqlText
protected string DebugSqlText { get; }
Property Value
ElementType
public abstract QueryElementType ElementType { get; }
Property Value
IsParameterDependent
public abstract bool IsParameterDependent { get; set; }
Property Value
ParentStatement
Used internally for SQL Builder
public SqlStatement? ParentStatement { get; set; }
Property Value
QueryType
public abstract QueryType QueryType { get; }
Property Value
SelectQuery
public abstract SelectQuery? SelectQuery { get; set; }
Property Value
SqlQueryExtensions
public List<SqlQueryExtension>? SqlQueryExtensions { get; set; }
Property Value
SqlText
public string SqlText { get; }
Property Value
Tag
public SqlComment? Tag { get; }
Property Value
Methods
CollectParameters()
[Obsolete("API will be removed in future versions")]
public SqlParameter[] CollectParameters()
Returns
GetTableSource(ISqlTableSource)
public abstract ISqlTableSource? GetTableSource(ISqlTableSource table)
Parameters
table
ISqlTableSource
Returns
IsDependedOn(SqlTable)
Indicates when optimizer can not remove reference for particular table
public virtual bool IsDependedOn(SqlTable table)
Parameters
table
SqlTable
Returns
PrepareQueryAndAliases(SqlStatement, AliasesContext?, out AliasesContext)
public static void PrepareQueryAndAliases(SqlStatement statement, AliasesContext? prevAliasContext, out AliasesContext newAliasContext)
Parameters
statement
SqlStatementprevAliasContext
AliasesContextnewAliasContext
AliasesContext
ToString(StringBuilder, Dictionary<IQueryElement, IQueryElement>)
public abstract StringBuilder ToString(StringBuilder sb, Dictionary<IQueryElement, IQueryElement> dic)
Parameters
Returns
WalkQueries<TContext>(TContext, Func<TContext, SelectQuery, SelectQuery>)
public abstract void WalkQueries<TContext>(TContext context, Func<TContext, SelectQuery, SelectQuery> func)
Parameters
context
TContextfunc
Func<TContext, SelectQuery, SelectQuery>
Type Parameters
TContext
Walk<TContext>(WalkOptions, TContext, Func<TContext, ISqlExpression, ISqlExpression>)
public virtual ISqlExpression? Walk<TContext>(WalkOptions options, TContext context, Func<TContext, ISqlExpression, ISqlExpression> func)
Parameters
options
WalkOptionscontext
TContextfunc
Func<TContext, ISqlExpression, ISqlExpression>
Returns
Type Parameters
TContext