Hi,
I am currently running into an issue where after i perform the following chained groupBy statement below, I cannot change the ordering of the fields in the write statement.
....
.groupBy(('id,'week,'year)) {
g => g.sum('soldQuantity -> 'aggrQuantity)
.average('soldQuantity -> 'avgQuantity)
....
.write(Csv(args('output), ",", fields = ('id, 'week, 'year, 'avgQuantity, 'aggrQuantity), quote = StringUtils.EMPTY))
In my chained groupBy statement I perform the sum first and the average second, but in my output I want to have the average first and the sum second. I know that I can just change the order in which I am doing my groupBy statement, but it seems like if I am specifying the fields in a particular order in my write stement, it should output the fields in that order regardless of the order in which I actually performed them in previous statements. Will changing the order of the fields in the write statement not actually order them in that way in the output?
Thanks!
Brian