title: How can I split a timestamp column into date and time in spark
body: <p>I want to split timestamp value into date and time.</p>
  
  <p>eg:</p>
  
  <pre><code>1/20/2016 3:20:30 PM
  1/20/2016 3:20:31 PM
  1/20/2016 3:20:32 PM
  1/20/2016 3:20:32 PM
  1/20/2016 3:20:32 PM
  1/20/2016 3:20:33 PM
  1/20/2016 3:20:34 PM
  1/20/2016 3:20:34 PM
  </code></pre>
  
  <p>needs to be split into 1/20/2016  and 3:20:30 PM</p>
  
  <p>using sql spilt function I am unable to process it correctly</p>
  
  <pre><code>split_col = pyspark.sql.functions.split(df['ServerTime'], ' ')
  df_date = df.withColumn('Date', split_col.getItem(0))
  df_time = df.withColumn('Time', split_col.getItem(1))
  </code></pre>
  
  <p>Any help guys????</p>