title: Python pd.read_csv, .to_sql different length than actual data
body: <p>I have a database with ~ 50million rows. After reading to a database I only get 21,000 rows. What am I doing wrong? Thanks.</p>
  
  <pre><code>chunksize = 100000
  csv_database = create_engine('sqlite:///csv_database.db', pool_pre_ping=True)
  
  
  
  i=0
  j=0
  q=0
  for df in pd.read_csv(filename, chunksize = chunksize, iterator = False):
  #    df = df.rename(columns={c: c.replace(' ', '') for c in df.columns})
      df.index += j
      i+= 1
      df.to_sql('table', csv_database, if_exists='append')
      j = df.index[-1] +1
      q+=1
      print("q: " + repr(q))
  
  
  
  
  columnx = df.iloc[:,0]
  columny = df.iloc[:,1]
  columnz = df.iloc[:,2]
  columnmass = df.iloc[:,3]
  
  out: [21739 rows x 1 columns] etc etc.
  
  in[19]: len(df)
  Out[19]: 21739
  </code></pre>