Spark aggregate question
Hi All. I have a dumb spark question after watching Will's video on aggregates in Spark.
Whats the difference between
df.groupBy('somecolumn').max('somemeasure').show()
and
df.groupBy('somecolumn').agg(max('somemeasure')).show()
?
in the example its about aliasing the column name but what's the difference using the agg function?
1
2 comments
Timothy Blackwell
2
Spark aggregate question
Learn Microsoft Fabric
skool.com/microsoft-fabric
Helping passionate analysts, data engineers, data scientists (& more) to advance their careers on the Microsoft Fabric platform.
Leaderboard (30-day)
powered by