title: Spark SQL: apply aggregate functions to a list of columns
body: <p>Is there a way to apply an aggregate function to all (or a list of) columns of a dataframe, when doing a <code>groupBy</code>? In other words, is there a way to avoid doing this for every column:</p>
  
  <pre class="lang-py prettyprint-override"><code>df.groupBy("col1")
    .agg(sum("col2").alias("col2"), sum("col3").alias("col3"), ...)
  </code></pre>