title: How to filter a Spark dataframe by a boolean column?
body: <p>I created a dataframe that has the following schema:</p>
  <pre class="lang-none prettyprint-override"><code>In [43]: yelp_df.printSchema()
  root
   |-- business_id: string (nullable = true)
   |-- cool: integer (nullable = true)
   |-- date: string (nullable = true)
   |-- funny: integer (nullable = true)
   |-- id: string (nullable = true)
   |-- stars: integer (nullable = true)
   |-- text: string (nullable = true)
   |-- type: string (nullable = true)
   |-- useful: integer (nullable = true)
   |-- user_id: string (nullable = true)
   |-- name: string (nullable = true)
   |-- full_address: string (nullable = true)
   |-- latitude: double (nullable = true)
   |-- longitude: double (nullable = true)
   |-- neighborhoods: string (nullable = true)
   |-- open: boolean (nullable = true)
   |-- review_count: integer (nullable = true)
   |-- state: string (nullable = true)
  </code></pre>
  <p>I want to select only the records with the &quot;open&quot; column that is &quot;true&quot;. The following command I run in PySpark returns nothing:</p>
  <pre><code>yelp_df.filter(yelp_df[&quot;open&quot;] == &quot;true&quot;).collect()
  </code></pre>