public void PivotBuild_By_AggregateFunctionFuntionName_Property_Expression_ViceVersa(string aggFunctionName)
        {
            var pivotTable =
                PivotBuilder
                .BuildPivotTable <OrderByYear, decimal?, decimal>(orders,
                                                                  o => o.OrderYear,
                                                                  o => o.EmployeeId,
                                                                  aggFunctionName,
                                                                  o => o.Price);

            VerifyPivotTable(pivotTable);
        }
        public void Pivot_Build_With_AggregateFunction_Avg()
        {
            var pivotTable =
                PivotBuilder
                .BuildPivotTable <OrderByYear, decimal?, decimal>(orders,
                                                                  o => o.EmployeeId,
                                                                  o => o.OrderYear,
                                                                  (s, v) => ((s + v) / 2.0m).AsDecimal(),
                                                                  o => o.Price);

            VerifyPivotTable(pivotTable);
        }
        public void Pivot_Build_With_AggregateFunction_Sum()
        {
            var pivotTable =
                PivotBuilder
                .BuildPivotTable <OrderByYear, decimal?, decimal>(orders,
                                                                  o => o.EmployeeId,
                                                                  o => o.OrderYear,
                                                                  (s, v) => s + v.GetValueOrDefault(0m),
                                                                  o => o.Price);

            VerifyPivotTable(pivotTable);
        }
        public void Pivot_Build_With_AggregateFunction_Count()
        {
            var pivotTable =
                PivotBuilder
                .BuildPivotTable <OrderByYear, decimal?, int>(orders,
                                                              o => o.EmployeeId,
                                                              o => o.OrderYear,
                                                              (s, v) => s + 1,
                                                              o => o.Price);

            VerifyPivotTable(pivotTable);
        }
        public void PivotBuild_By_AggregateFunctionFuntionName_Property_Name(string aggFunctionName)
        {
            var pivotTable =
                PivotBuilder
                .BuildPivotTable <OrderByYear, decimal?, decimal>(orders,
                                                                  "EmployeeId",
                                                                  "OrderYear",
                                                                  aggFunctionName,
                                                                  "Price");

            VerifyPivotTable(pivotTable);
        }