title: Spark: How to convert a Dataset[(String , array[int])] to Dataset[(String, int, int, int, int, ...)] using Scala
body: <p>The Dataset I have has the following schema: <code>[String, array[int]]</code>. Now, I want to convert it to a Dataset (or Dataframe) with the following schema: <code>[String, int, int, int, ...]</code>.  Note that <code>array[int]</code> is dynamic, it can therefore have different length for different rows.  </p>