title: Add months to date column in Spark dataframe
body: <p>I have a scenario where I want to add months to a date column in spark <code>DataFrame</code> which has two columns with data type (Date, Int)</p>
  
  <p>e.g.</p>
  
  <pre><code>df.show()
  </code></pre>
  
  <pre class="lang-none prettyprint-override"><code>data_date months_to_add
  2015-06-23 5
  2016-07-20 7
  </code></pre>
  
  <p>I want to add a new column which will have a new date (After adding months to existing date) and output will look like below-</p>
  
  <pre class="lang-none prettyprint-override"><code>data_date month_to_add new_data_date
  2015-06-23 5           2015-11-23
  2016-07-20 1           2016-8-20
  </code></pre>
  
  <p>I have tried below piece of code, but it does not seems to be working-</p>
  
  <pre><code>df = df.withColumn("new_data_date", a
    dd_months(col("data_date"), col("months_to_add")))
  </code></pre>
  
  <p>it gives me error-</p>
  
  <pre class="lang-none prettyprint-override"><code>'Column' object is not callable
  </code></pre>
  
  <p>Please help me if there is any method to achieve this without using SQL query on top of dataframe. </p>