Table of Contents

Class DataQuery

Namespace
CMS.DataEngine
Assembly
CMS.DataEngine.dll

Queries particular database data or defines parameters for data selection

public class DataQuery : DataQueryBase<DataQuery>, IDataQuery<DataQuery>, IDataQuerySettings<DataQuery>, IWhereCondition<DataQuery>, IQueryParameters<DataQuery>, IDataQuery, IDataQuerySettings, IWhereCondition, IQueryParameters, IQueryObjectWithValue, IQueryObject
Inheritance
object
DataQuery
Implements
Inherited Members
Extension Methods

Constructors

DataQuery()

Default constructor

public DataQuery()

DataQuery(string)

Creates a query based on the given query name

public DataQuery(string queryName)

Parameters

queryName string

Full query name

DataQuery(string, string)

Creates a query based on the given query name

public DataQuery(string className, string queryName)

Parameters

className string

Class name

queryName string

Query name

Methods

Combine(IEnumerable<IDataQuery>, IEnumerable<string>, string)

Combines several queries into a single result

public static DataQuery Combine(IEnumerable<IDataQuery> queries, IEnumerable<string> operators, string connectionStringName = null)

Parameters

queries IEnumerable<IDataQuery>

Queries

operators IEnumerable<string>

Operators between queries

connectionStringName string

Specifies connection string against which the query will be executed. If connection string name is not specified, uses the default database.

Returns

DataQuery

Combine<TQuery>(IEnumerable<TQuery>, IEnumerable<string>, string)

Combines several queries into a single result

public static TQuery Combine<TQuery>(IEnumerable<TQuery> queries, IEnumerable<string> operators, string connectionStringName = null) where TQuery : class, IDataQuery, new()

Parameters

queries IEnumerable<TQuery>

Queries

operators IEnumerable<string>

Operators between queries

connectionStringName string

Specifies connection string against which the query will be executed. If connection string name is not specified, uses the default database.

Returns

TQuery

Type Parameters

TQuery

FromList(IEnumerable<int>)

Creates a materialized DataQuery from the given list of IDs

public static DataQuery FromList(IEnumerable<int> ids)

Parameters

ids IEnumerable<int>

List of IDs

Returns

DataQuery