I would like to ask if there is a way of specifying the column name of a data frame aggregation. For example If I do:
customerDF.groupBy("state").agg(max($"discount")) the name of my aggregated column will be: MAX('discount) Is there a way of changing the name of that column to something else on the fly, and not after performing the aggregation? thanks -- Cesar Flores