title: sqlSave in R to create and save a dataframe to an sql table
body: <p>Hi I am using R to save a data frame into a DB2 SQL table. I seem to be able to create the table skeleton, but not append the data to the table -</p>
  
  <pre><code>&gt;df &lt;- read.csv("dat.csv")
  </code></pre>
  
  <p>where dat.csv is a csv with no headers, just raw data in two columns</p>
  
  <p>then i create the table:</p>
  
  <pre><code>&gt;sqlQuery(channel, "create table sqltable 
                     (
                     col1  int,
                     col2  float
                     )"
           (
  </code></pre>
  
  <p>where I confirm the table is created by being able to select the empty table "sqltable" on the database</p>
  
  <p>so now I need to add the data from "dat.csv" into "sqltable" by doing:</p>
  
  <pre><code>&gt;sqlSave(channel, df, "sqltable", verbose=T, fast=T, append=T)
  
  no: 1 rownames 1/***/no: 2 col1 31105/***/no: 3 col2 0.001/***/
  no: 2 rownames 1/***/no: 2 col1 31106/***/no: 3 col2 0.023/***/
  no: 3 rownames 1/***/no: 2 col1 31107/***/no: 3 col2 1.456/***/
  no: 4 rownames 1/***/no: 2 col1 31108/***/no: 3 col2 0.001/***/
  no: 5 rownames 1/***/no: 2 col1 31109/***/no: 3 col2 2.102/***/
  </code></pre>
  
  <p>all seems good until I do:</p>
  
  <pre><code>&gt;sqlQuery(channel,"select * from sqltable")
  
  [1] COL1     COL2
  &lt;0 rows&gt; or 0-length row.names
  </code></pre>
  
  <p>the sqlSave command clearly picks up the data from dat.csv, so why is it not added to the table? what am I doing wrong?</p>