title: AttributeError: 'DataFrame' object has no attribute 'timestamp'
body: <p>I want to select only those rows that have a timestamp that belongs to last 36 hours. My PySpark DataFrame <code>df</code> has a column <code>unix_timestamp</code> that is a timestamp in seconds.
  This is my current code, but it fails with the error <code>AttributeError: 'DataFrame' object has no attribute 'timestamp'</code>. I tried to change it to <code>unix_timestamp</code>, but it fails all the time.</p>
  
  <pre><code>import datetime
  hours_36 = (datetime.datetime.now() - datetime.timedelta(hours = 36)).strftime("%Y-%m-%d %H:%M:%S")
  
  df = df.withColumn("unix_timestamp", df.unix_timestamp.cast("timestamp")).filter(df.timestamp &gt; hours_36)
  </code></pre>