title: Spring batch xlxs file to MySql database
body: <p>i'm new with spring batch and I implemented an example of a cvs file and which colmuns are separated by comma
  But I have an xlxs file wich contain just colmuns without separator  I want to insert the data without using separators in my xlxs files just columns.</p>
  
  <p>Here is the contents of job-report </p>
  
  <pre><code>&lt;bean id="report" class="com.mkyong.model.Report" scope="prototype" /&gt;
  &lt;batch:job id="reportJob"&gt;
  &lt;batch:step id="step1"&gt;
    &lt;batch:tasklet&gt;
      &lt;batch:chunk reader="cvsFileItemReader" writer="mysqlItemWriter"
          commit-interval="2"&gt;
      &lt;/batch:chunk&gt;
    &lt;/batch:tasklet&gt;
  &lt;/batch:step&gt;
  </code></pre>
  
  <p></p>
  
  <pre><code>  &lt;bean id="cvsFileItemReader" class="org.springframework.batch.item.file.FlatFileItemReader"&gt;
  
  &lt;!-- Read a csv file --&gt;
  &lt;property name="resource" value="classpath:cvs/report.csv" /&gt;
  
  &lt;property name="lineMapper"&gt;
      &lt;bean class="org.springframework.batch.item.file.mapping.DefaultLineMapper"&gt;
        &lt;!-- split it --&gt;
        &lt;property name="lineTokenizer"&gt;
              &lt;bean
            class="org.springframework.batch.item.file.transform.DelimitedLineTokenizer"&gt;
              &lt;property name="names" value="date,impressions,clicks,earning" /&gt;
          &lt;/bean&gt;
        &lt;/property&gt;
        &lt;property name="fieldSetMapper"&gt;
               &lt;!-- return back to reader, rather than a mapped object. --&gt;
               &lt;!--
           &lt;bean class="org.springframework.batch.item.file.mapping.PassThroughFieldSetMapper" /&gt;
                --&gt;
            &lt;!-- map to an object --&gt;
            &lt;bean
              class="org.springframework.batch.item.file.mapping.BeanWrapperFieldSetMapper"&gt;
              &lt;property name="prototypeBeanName" value="report" /&gt;
            &lt;/bean&gt;
        &lt;/property&gt;
  
        &lt;/bean&gt;
    &lt;/property&gt;
  
    &lt;/bean&gt;
   &lt;bean id="mysqlItemWriter"
  class="org.springframework.batch.item.database.JdbcBatchItemWriter"&gt;
  &lt;property name="dataSource" ref="dataSource" /&gt;
  &lt;property name="sql"&gt;
    &lt;value&gt;
          &lt;![CDATA[
              insert into RAW_REPORT(DATE,IMPRESSIONS,CLICKS,EARNING)
          values (:date, :impressions, :clicks, :earning)
          ]]&gt;
    &lt;/value&gt;
  &lt;/property&gt;
  &lt;!-- It will take care matching between object property and sql name parameter --&gt;
  &lt;property name="itemSqlParameterSourceProvider"&gt;
      &lt;bean
      class="org.springframework.batch.item.database.BeanPropertyItemSqlParameterSourceProvider" /&gt;
  &lt;/property&gt;
  </code></pre>
  
  <p></p>
  
  <p>when i execute my code this error appears </p>
  
  <pre><code>org.springframework.batch.item.file.FlatFileParseException: Parsing error at line: 1 in resource=[class path resource [cvs/report.csv]], input=[123456;139,237;37;123456]
  </code></pre>
  
  <p>PS : In my file each columns contains values ​​without separator.</p>