Skip to content

SqlStatement class

Represents the result of performing BuildSQL command.

public class Korzh.EasyQuery.Db.SqlStatement
: QueryBuilderResult
TypeNameDescription
Boolean_needGroupBy
TypeNameDescription
StringEntitySqlGets the “entity SQL” (for Entity Framework).
SqlExtrasExtraClausesGets the Korzh.EasyQuery.Db.SqlExtras object which defines some extra clauses of generated query.
DbQueryFormatsFormatsGets the Korzh.EasyQuery.Db.DbQueryFormats object in the parent query.
StringFromClauseGets the text of FROM clause.
StringGroupClauseGets the text of GROUP BY clause.
BooleanHasPagingGets or sets a value indicating whether the result query statement includes paging clauses.
StringHavingClauseGets the text of HAVING clause.
BooleanNeedGroupByGets a value indicating whether GROUP BY section is necessary in result SQL.
StringOrderClauseGets the text of ORDER BY clause.
ResultSetPortionPortionAllows to specify a portion of result set to return.
DbQueryQueryGets the query.
StringRecordCountAliasGets the alias for Total Records column. This option works only if RecordCountTemplate is not empty
ResultTableRootTableGets the root (first) table used in query.
StringSelectClauseGets the text of SELECT clause.
StringSQLGets the text of result SQL statement.
StringWhereClauseGets the text of WHERE clause.
TypeNameDescription
voidAddCondition(String s)Adds text of some condition to WHERE clause.
voidAddHavingCondition(String s)Adds text of some condition to HAVING clause.
BooleanAddJoinToAppropriateResultTable(ResultTable resTable, Table table, String condExpr)
voidAddToAppropriateJoin(Table table, String condExpr)
voidAddToHavingClause(String s)Adds some text to HAVING clause.
voidAddToWhereClause(String s)Adds some text to WHERE clause.
voidClearAll()Clears all clauses.
voidClearHavingClause()Clears the HAVING clause.
voidClearWhereClause()Clears the WHERE clause.
StringGetSql(String selectExpr, String orderExpr)Gets the SQL statement with custom SELECT and ORDER BY clauses.
StringGetStatement()Returns the statement (SQL, filter expression, etc - depending on the concrete QueryBuilderResult type).
voidSetRootTable(Table ATable)
StringToString()Returns a System.String that represents this instance.