reduceContext.values
Property Description |
This array holds all values for a unique key passed to the reduce stage. These values are listed in lexicographical order. When the map/reduce process includes a map stage, the key-value pairs passed to the reduce stage are derived from the values written by mapContext.write(options). When the map stage is skipped, the values are determined by the getInputData stage:
Note:
Each value cannot exceed 1 megabyte. |
Type |
string[] |
Since |
2015.2 |
Syntax
The following code snippet shows the syntax for this member. It's not a functional example. For a complete script example, see SuiteScript 2.x Map/Reduce Script Code Samples.
...
function reduce(context)
{
context.write({
key: context.key ,
value: context.values.length
});
}
...