Class ReportQuery
- Namespace
- Dynamicweb.Tracking.Reporting
- Assembly
- Dynamicweb.Core.dll
Represents a report query.
- Inheritance
-
Report
Query
- Inherited Members
Constructors
ReportQuery()
Initializes a new instance of the Report
ReportQuery(DateTime, DateTime)
Initializes a new instance of the Report
Parameters
Properties
Aggregates
Gets or sets the aggregates.
Property Value
- List<Query
Aggregate > The aggregates.
DateFrom
Gets or sets the date from.
Property Value
- Date
Time The date from.
DateTo
Gets or sets the date to.
Property Value
- Date
Time The date to.
Filters
Gets or sets the filters.
Property Value
- List<Query
Condition > The filters.
Groups
Gets or sets the groups.
Property Value
QueryAggregates
Gets or sets the aggregates.
Property Value
- List<Query
Aggregate >Report The aggregates.
Sorting
Gets or sets the sorting.
Property Value
Sources
Gets or sets the sources.
Property Value
- List<Data
Source > The sources.
Methods
AddAggregateWithAlias<T>(AggregateType, string, string?, bool)
Adds the aggregate.
public QueryAggregate AddAggregateWithAlias<T>(AggregateType aggregate, string name, string? alias, bool allowUnsafe = false)
Parameters
aggregate
AggregateType The aggregate.
name
stringThe name.
alias
stringThe alias of the aggregate allowing it to be referenced in the query.
allowUnsafe
boolif set to
true
[allow unsafe].
Returns
Type Parameters
T
AddAggregate<T>(AggregateType, string, bool)
Adds the aggregate.
public QueryAggregate AddAggregate<T>(AggregateType aggregate, string name, bool allowUnsafe = false)
Parameters
aggregate
AggregateType The aggregate.
name
stringThe name.
allowUnsafe
boolif set to
true
[allow unsafe].
Returns
Type Parameters
T
AddEventSource(string)
Adds the event source.
Parameters
alias
stringThe source alias.
Returns
AddFilter(string, OperatorType, bool)
Adds the filter.
Parameters
name
stringThe name.
operatorType
OperatorType Type of the operator.
allowUnsafe
boolif set to
true
[allow unsafe].
Returns
AddFilter(string, OperatorType, object, bool)
Adds the filter.
public QueryCondition? AddFilter(string name, OperatorType operatorType, object value, bool allowUnsafe = false)
Parameters
name
stringThe name.
operatorType
OperatorType Type of the operator.
value
objectThe value.
allowUnsafe
boolif set to
true
[allow unsafe].
Returns
AddFilter(string, string, OperatorType)
Adds the filter.
Parameters
name
stringThe name.
foreignName
stringThe foreign name.
operatorType
OperatorType Type of the operator.
Returns
AddGrouping(string, Func<string, string>, Func<string[], string>?)
Adds the grouping.
public Grouping? AddGrouping(string name, Func<string, string> nameMapping, Func<string[], string>? concatenation = null)
Parameters
name
stringThe name.
nameMapping
Func<string, string>The name mapping.
concatenation
Func<string[], string>The concatenation.
Returns
AddGroupingWithoutDelimitedIdentifier(string, Func<string, string>, Func<string[], string>?)
Adds a Grouping for the given named column.
public Grouping? AddGroupingWithoutDelimitedIdentifier(string name, Func<string, string> nameMapping, Func<string[], string>? concatenation = null)
Parameters
name
stringThe name of the columns to group by.
nameMapping
Func<string, string>The mapping function to retrieve labels for the given columns.
concatenation
Func<string[], string>The concatenation function.
Returns
AddGroupings(string[], Func<string, string>, DateGrouping?, Func<string[], string>?)
Adds the groupings.
public Grouping? AddGroupings(string[] names, Func<string, string> nameMapping, DateGrouping? dateGrouping, Func<string[], string>? concatenation = null)
Parameters
names
string[]The names.
nameMapping
Func<string, string>The name mapping.
dateGrouping
DateGrouping ?The date grouping.
concatenation
Func<string[], string>The concatenation.
Returns
AddGroupings(string[], Func<string, string>, DateGrouping?, Func<string[], string>?, bool)
Adds Groupings for the given named columns.
public Grouping? AddGroupings(string[] names, Func<string, string> nameMapping, DateGrouping? dateGrouping, Func<string[], string>? concatenation = null, bool allowUnsafeColumnNames = false)
Parameters
names
string[]The names of the columns to group by.
nameMapping
Func<string, string>The mapping function to retrieve labels for the given columns.
dateGrouping
DateGrouping ?The Date
Grouping concatenation
Func<string[], string>The concatenation function.
allowUnsafeColumnNames
boolfalse
if the given column names should be treated as delimited identifiers; otherwisetrue
. Default isfalse
.
Returns
AddQueryAggregate(ReportQuery, string)
Adds the query aggregate.
Parameters
query
ReportQuery The report query.
name
stringThe name.
Returns
AddSessionSource()
Adds the session source.
Returns
AddSessionSource(string)
Adds the session source.
Parameters
alias
stringThe source alias.
Returns
AddSource(string)
Adds the source.
Parameters
name
stringThe name.
Returns
AddSource(string, string)
Adds the source.
Parameters
Returns
AddViewSource(bool, string)
Adds the view source.
Parameters
addReferencesToTrackingSession
boolAdd references to traking session table.
alias
stringThe source alias.
Returns
GetGroupingNameMapping(int)
Gets the grouping name mapping.
Parameters
index
intThe index.