GroupBy with multiple fields
Posted: Thu May 25, 2023 8:39 pm
Hi,
How can do multiple group-by consolidation? As mentions in the docs that can be done, But I didn't find a way. For example suppose I wish to group by by both "Country" and "City":
I get the following error:
"Unkown field type: Count of City"
Just doing
Works great.
What am I doing wrong?
Thanks,
How can do multiple group-by consolidation? As mentions in the docs that can be done, But I didn't find a way. For example suppose I wish to group by by both "Country" and "City":
Code: Select all
S:= TSummary.Create(nil);
S.AddGroupBy(Data['Country']);
S.AddGroupBy(Data['City']);
S.AddMeasure( Data['City'], TAggregate.Count );
"Unkown field type: Count of City"
Just doing
Code: Select all
S.AddGroupBy(Data['City']);
S.AddMeasure( Data['City'], TAggregate.Count );
What am I doing wrong?
Thanks,