Contents: MashupHub User and Administrator Guide : Mashup Center 2.0
Use the Minimum (Min) function to find the smallest numeric value from a set of elements.
To create an output element that determines the minimum value from a set of elements from an input feed, the elements used must be nested within a higher level element.
For example, an input operator to the current operator contains an element named feed
that contains several child elements named entry
To determine the minimum value of the <entry>
elements, for the Expression Value
parameter you would select Specify a value from the Input tree
. In the tree, you would select the <entry>
element or a child element of the <entry>
A numeric value that you want to return the minimum value from.
For the Expression Value parameter you can:
- Specify a text value. (For this function, specify a numeric value.)
- Specify a function value.
- Use a variable to return the value.
- Specify a value from the Input tree.
When you apply the Min function to an output element, the output feed contains a single element with a numeric value.
In the following example of an input feed, the containing element is the school
element that contains instances of the child element studentCount
, and the value of studentCount
is the number of students in the room:
The Expression Value
for the Min function would look similar to:
In this example, when you use the Min function to create a new output feed element, all of the instances of studentCount
from the input feed are used as input. The output feed contains a single element with a numeric value that represents the minimum value of the studentCount
The preview of the output feed displays the output element, and the value of the element is the smallest value of the studentCount
Parent topic: Functions : Mashup Center 2.0
Using aggregate functions effectively : Mashup Center 2.0
Functions : Mashup Center 2.0