Interface IGroupByCommand
Commands for specifying grouping columns for use with several AggregateTransformFactory overloads. Unlike IGroupByCopyCommand, this interface is not used when the worker must explicitly copy individual grouping columns to the output rows. Also see the examples in Dataflow Aggregations.
Inherited Members
Namespace: actionETL
Assembly: actionETL.dll
Syntax
public interface IGroupByCommand : IFluentInterface
Remarks
The aggregation functions follow the SQL-92 standard:
- The aggregation functions always return one row for each grouping in the input set
- An empty input set produces an empty output set
Countaggregations support nullable input column types. Non-Countaggregations support nullable input column value types if both input and output columns are nullable.- Null input column values are not included in aggregations (
CountRowshowever doesn't look at input column values at all) - If the aggregation result type (usually the same as the input column type), can be cast to the output column type, then they can have different types, e.g.
longtodouble SumandAverageadditions are checked for overflow,Count*additions are not
Methods
Name(String)
Specifies column to group by. To group by multiple columns, call this method multiple times.
Note that grouping by null column values is supported.
Also note that since the worker does not explicitly copy the grouping column to the output column, the grouping column can optionally be read only or a computed property.
string columns use a case sensitive ordinal equality test. To use a
different string order, either add a column (i.e. property or field)
to the row with the desired content (e.g. all upper case) and group on that,
or use an overload where you can specify a custom equality comparer.
Also see Create<T, TKey>(Func<T, TKey>).
Declaration
IGroupByCommand Name(string columnName)
Parameters
| Type | Name | Description |
|---|---|---|
| String | columnName | Name of the input group by column. |
Returns
| Type | Description |
|---|---|
| IGroupByCommand | The instance itself, for chaining multiple commands together. |
Exceptions
| Type | Condition |
|---|---|
| ArgumentException |
|
| ArgumentNullException |
|
| InvalidOperationException | Found more than one member match in type. |