title: Pyspark - How to name partitions in ISO8601 format over integer columns
body: <p>I have a DataFrame that looks like this:</p>
  <pre><code>+--------------------+----+-----+---+----+
  |       action       |year|month|day|hour|
  +--------------------+----+-----+---+----+
  |check in            |2022|    4|  3|  23|
  |go shopping         |2022|    4|  4|  11|
  |go eat              |2022|    4|  5|  12|
  |go watch a movie    |2022|    4|  6|  14|
  |go out for a drink  |2022|    4|  6|  18|
  +--------------------+----+-----+---+----+
  
  root
   |-- action: string (nullable = false)
   |-- year: integer (nullable = true)
   |-- month: integer (nullable = true)
   |-- day: integer (nullable = true)
   |-- hour: integer (nullable = true)
  </code></pre>
  <p>When I save this dataframe to disk, I would like the table to be partitioned over the datetime fields, i.e:</p>
  <pre class="lang-py prettyprint-override"><code>df.write.format(&quot;parquet&quot;).partitionBy(
      &quot;year&quot;, &quot;month&quot;, &quot;day&quot;, &quot;hour&quot;
  ).save(path)
  </code></pre>
  <p>I would also like to be able to add padded zero to the day, month, and hour partition folder name, so that they look like this:</p>
  <pre><code>table/year=2022/month=09/...
  </code></pre>
  <p>and <strong>not this</strong>:</p>
  <pre><code>table/year=2022/month=9/...
  </code></pre>
  <p>Is it possible to do so in Pyspark, in a way that isn't intrusive to the table, and doesn't involve changing the table schema?</p>
  <p>Thank you for your time.</p>