This how-to guide guides in identifying the maximum value in a data set by using the Max By function of the Aggregate operator.
Configuration
Let’s say you require the name of the oldest dog from a list of dogs. Begin with a Data Table component that stores information regarding dogs and their respective ages. Then, configure a Data Workflow to identify and return the name of the oldest dog.
These instructions assume you have a new module open, saved, and with a title.
Configure the Data Table Component
Begin by adding your Data Table component to store a list of dogs and their ages.
In the Module Builder, drag and drop a Data Table component onto your canvas.
In the Property ID field, enter
dtDogs.In the data table, enter the following:
#
A
B
1
name
age
2
Ivy
7
3
Lucy
10
4
Wally
1
5
Nacho
5
6
Thor
5
7
Holly
13

Click Save Component.
Configure the Data Workflow Component
Next, configure your Data Workflow component and an Aggregate operator to identify the oldest dog. Then, you’ll display the results using a Console operator.
Drag and drop a Data Workflow onto your canvas, placing it below your Data Table component.
In the Property ID and Canvas Label Text fields, enter
dwfOldest.
Configure the Input Operator
Drag and drop an Input operator onto your Data Workflow canvas.
Configure the operator's Info window as follows:
Setting
Value
Category
Input
Component
dtDogs
Required
Yes
Source
Default
Configure the Aggregate Operator
Drag and drop an Aggregate operator onto your Data Workflow canvas.
Configure the operator's Info window as follows:
Setting
Value
Category
Aggregate By
Label
Oldest Dog
Aggregation Type
Max By
Join Group Keys
No
Group Key
Value Key
age
Connect the output port (right) of the
dtDogsInput operator to the input port (left) of theOldest DogAggregate operator.
Configure the Console Operator
Drag and drop a Console operator onto your Data Workflow canvas.
Configure the operator's Info window as follows:
Setting
Value
Category
Console
Label
Who is the oldest dog?
Connect the output port (right) of the
Oldest DogAggregate operator to the input port (left) of theWho is the oldest dog?Console operator.
Click Save Component.
Configure the Button Component
Lastly, configure a Button component to trigger your Data Workflow.
Drag and drop a Button component onto your canvas, placing it below your Data Workflow component.
In the Property ID field, enter
btnOldestDog.In the Label Text field, enter
Find Oldest Dog.From the Action Type drop-down, select Event.
From the On Click drop-down, select dwfOldest.

Click Save Component.
Save your module.
Here's how your configured module looks in the Module Builder:

Preview your module in Express View and open the DevTools Console. Click the Find the Oldest Dog button and you'll see the oldest dog in your Who is the oldest dog? Console operator.

This how-to guide guides in identifying the maximum value in a data set by using the Max By function of the Aggregate operator.
Configuration
Let’s say you require the name of the oldest dog from a list of dogs. Begin with a Data Table component that stores information regarding dogs and their respective ages. Then, configure a Data Workflow to identify and return the name of the oldest dog.
These instructions assume you have a new module open, saved, and with a title.
Configure the Data Table Component
Begin by adding your Data Table component to store a list of dogs and their ages.
In the Module Builder, drag and drop a Data Table component onto your canvas.
In the Label and Property Name fields, enter
dtDogs.In the data table, enter the following:
#
A
B
1
name
age
2
Ivy
7
3
Lucy
10
4
Wally
1
5
Nacho
5
6
Thor
5
7
Holly
13

Click Save.
Configure the Data Workflow Component
Next, configure your Data Workflow component and an Aggregate operator to identify the oldest dog. Then, you’ll display the results using a Console operator.
Drag and drop a Data Workflow onto your canvas, placing it below your Data Table component.
In the Canvas Label Text and Property Name fields, enter
dwfOldest.
Configure the Input Operator
Drag and drop an Input operator onto your Data Workflow canvas.
Configure the operator's Info window as follows:
Setting
Value
Category
Input
Component
dtDogs
Required
Yes
Source
Default
Configure the Aggregate Operator
Drag and drop an Aggregate operator onto your Data Workflow canvas.
Configure the operator's Info window as follows:
Setting
Value
Category
Aggregate By
Label
Oldest Dog
Aggregation Type
Max By
Join Group Keys
No
Group Key
Value Key
age
Connect the output port (right) of the
dtDogsInput operator to the input port (left) of theOldest DogAggregate operator.
Configure the Console Operator
Drag and drop a Console operator onto your Data Workflow canvas.
Configure the operator's Info window as follows:
Setting
Value
Category
Console
Label
Who is the oldest dog?
Connect the output port (right) of the
Oldest DogAggregate operator to the input port (left) of theWho is the oldest dog?Console operator.
Click Save.
Configure the Button Component
Lastly, configure a Button component to trigger your Data Workflow.
Drag and drop a Button component onto your canvas, placing it below your Data Workflow component.
In the Property ID field, enter
btnOldestDog.In the Label Text field, enter
Find Oldest Dog.From the Action Type drop-down, select Event.
From the On Click drop-down, select dwfOldest.

Click Save & Close.
Save your module.
Here's how your configured module looks in the Module Builder:

Preview your module in Express View and open the DevTools Console. Click the Find the Oldest Dog button and you'll see the oldest dog in your Who is the oldest dog? Console operator.
