title: Scala Option[java.util.Date] cannot be cast to Option[java.sql.Date]
body: <p>I have a Play form that looks like this:</p>
  
  <pre><code>val form = Form( tuple( 
          /* 5 more fields */ 
          "dueDate" -&gt; optional(date) 
  )  )
  </code></pre>
  
  <p>I'm trying to insert <code>"dueDate"</code> into an object in Slick. </p>
  
  <pre><code>newAuditForm.bindFromRequest.fold(
      errors =&gt; BadRequest(views.html.error(form)),
      success =&gt; {
          Database.forDataSource(DB.getDataSource()) withSession {
              Things.forInsert.insert Thing(
                  (success._6).asInstanceOf[Option[java.sql.Date]] 
              )
          }
      }
  )
  </code></pre>
  
  <p>where Slick only deals with <code>java.sql.Date</code>, and Play only deals with <code>java.util.Date</code> (?) in the <code>Form</code> object.</p>
  
  <p>Using <code>asInstanceOf</code> returns:</p>
  
  <pre><code>     ClassCastException: java.util.Date cannot be cast to java.sql.Date
  </code></pre>
  
  <p>There's got to be a way for me to write a rule for this cast to be possible ...
  would I need to write a <a href="https://stackoverflow.com/questions/931463/how-do-i-cast-a-variable-in-scala/932215#932215">new pattern matching rule</a>? </p>