First M/R script. Iterating through data; want to ...
# suitescript
w
First M/R script. Iterating through data; want to add information to a string for csv output - how to add data to str in M/R for file creation in summary stage? summaryContext.output.iterator seems only to show the count of records processed, not the data that was written in the reduceContext phase.
s
Copy code
summary.output.iterator().each(function (key, value) {}
Definitely contains the key/value from each
context.write()
in the reduce stage
w
Thanks. Was trying to put a custom object in context.write instead of the reduceContext data. Working now.