Class AbstractSqlGenerator
- Namespace
- CMS.DataEngine
- Assembly
- CMS.DataEngine.dll
SQL generator base
[Obsolete("Class is deprecated and will be removed in next version.")]
[ObsoleteSince(28, 2)]
public abstract class AbstractSqlGenerator : ISqlGenerator
- Inheritance
-
objectAbstractSqlGenerator
- Implements
- Derived
- Extension Methods
Fields
mExcludeColumns
Excluded columns of the document which are not included into the queries.
protected static string mExcludeColumns
Field Value
- string
Properties
ExcludeColumns
Gets or sets the excluded columns of the document which are not included into the queries.
public static string ExcludeColumns { get; set; }
Property Value
- string
GenerateWithExpand
Gets or sets whether With (EXPAND) should be generated in views.
public static bool GenerateWithExpand { get; set; }
Property Value
- bool
Methods
GetColumnList(string, string, bool, string)
Generates the column list for the SQL query.
public static string GetColumnList(string className, string excludedColumns, bool fullName, string tableName = null)
Parameters
className
stringClass name
excludedColumns
stringList of the excluded columns
fullName
boolGenerate full name, including the table name?
tableName
stringTable name
Returns
- string
GetPKWhereCondition(string)
Returns the where condition for given primary key (single or list separated by semicolon).
public virtual string GetPKWhereCondition(string pkName)
Parameters
pkName
stringPrimary key name (list)
Returns
- string
GetSqlQuery(string, SqlOperationTypeEnum)
Generates the given type of query for table specified by its className.
public virtual string GetSqlQuery(string className, SqlOperationTypeEnum queryType)
Parameters
className
stringClass name of the document data
queryType
SqlOperationTypeEnumQuery type
Returns
- string
IsColumnExcluded(string, string)
Returns true if the column is excluded.
public static bool IsColumnExcluded(string excludedColumns, string column)
Parameters
excludedColumns
stringList of excluded columns (starting and ending with semicolon ";")
column
stringColumn to check
Returns
- bool