title: R sqlite: update with two tables gives syntax error " near ".":
body: <p>I would like to do a UPDATE with two tables on sqlite. </p>
  
  <pre><code>x1 &lt;- data.frame(id = rep(1,3),
                    t = as.Date(c("2000-01-01","2000-01-15","2000-01-31"))
  )
  x1.h &lt;- 0
  x2 &lt;- data.frame(id = 1, start = as.Date("2000-01-14"))
  </code></pre>
  
  <p>The UPDATE is:</p>
  
  <pre><code>sqldf(paste("UPDATE x1"
          ," SET x1.h = 1"
          ," WHERE EXISTS (SELECT *"
          ,"               FROM x2"
          ,"               WHERE x1.id = x2.id"
          ,"                     AND x1.t &lt; x2.start"
          ,"               )"
          )
    )
  </code></pre>
  
  <p>I get the following error:</p>
  
  <pre><code>Error in sqliteExecStatement(con, statement, bind.data) : 
     RS-DBI driver: (error in statement: near ".": syntax error)
  </code></pre>
  
  <p>Has someone an idea what goes wrong? 
  Thanks for helps.</p>