title: Passing sqlContext as an implicit parameter in Spark
body: <p>I have a function in a Scala object which has the following signature</p>
  
  <pre><code>def f(v1:Int)(implicit sqlContext: SQLContext)
  </code></pre>
  
  <p>when I try to call this function from spark-shell I call it like</p>
  
  <pre><code>f(1)
  </code></pre>
  
  <p>and I expect the existing sqlContext gets passed to it implicitly but it doesn't. How can I make it to work so the sqlContext get passed to this function automatically?</p>
  
  <p>--------------update-------------------</p>
  
  <p>I tried to import sqlContext.implicits._ in the spark-shell before calling my function but it didn't help</p>