title: How do I check for equality using Spark Dataframe without SQL Query?
body: <p>I want to select a column that equals to a certain value. I am doing this in scala and having a little trouble.</p>
  
  <p>Heres my code</p>
  
  <pre><code>df.select(df("state")==="TX").show()
  </code></pre>
  
  <p>this returns the state column with boolean values instead of just TX</p>
  
  <p>Ive also tried</p>
  
  <pre><code>df.select(df("state")=="TX").show() 
  </code></pre>
  
  <p>but this doesn't work either.</p>