title: spark - set null when column not exist in dataframe
body: <p>I'm loading many versions of JSON files to spark DataFrame.
  some of the files holds columns A,B
  and some A,B,C or A,C..</p>
  
  <p>If I run this command </p>
  
  <pre><code>from pyspark.sql import SQLContext
  
  sqlContext = SQLContext(sc)
  
  df = sqlContext.sql("SELECT A,B,C FROM table")
  </code></pre>
  
  <p>after loading several I can get error "column not exist" I loaded only files that are not holding column C.
  How can set this value to <code>null</code> instead of getting error?</p>