title: Postgresql Parameter Issue $1
body: <p>I am working on setting up a database, building a custom Upsert as Postgresql apparently doesn't have that yet. Anyway my parameters aren't playing nicely. </p>
  
  <p>I am using Martini. </p>
  
  <p>This code:</p>
  
  <pre><code>func CreateBook(ren render.Render, r *http.Request, db *sql.DB) {
      _, err := db.Query("INSERT INTO books (title, first, last, class) SELECT $1, $2, $3, $4 WHERE NOT EXISTS (SELECT * FROM books WHERE title = $1)",
      r.FormValue("title"),
      r.FormValue("first"),
      r.FormValue("last"),
      r.FormValue("class"))
  
      PanicIf(err)
  </code></pre>
  
  <p>Throws this error:</p>
  
  <pre><code>pq: inconsistent types deduced for parameter $1
  </code></pre>
  
  <p>I am fairly certain it's some kind of typecasting issue with the second $1 but none of the rational solutions seem to make sense. </p>
  
  <p>Its a stupid question with hopefully an easy answer but I haven't been able to find any answers anywhere else.</p>