<?xml version="1.0" encoding="UTF-8"?>

<!--
	read csv data from first 4 row of an excel file (see renderer
	section) and write sql to standard output (see writer section)
	using mysql dialect (grammar section)
-->
<root>
  <!-- CONFIGURATOR DATA -->
  <descriptor version="1"/>

  <!-- DEFINE HERE TABLE STRUCTURE -->
  <structure tablename="tablename">
    <field name="stringfield1"     type="VARCHAR"/>
    <field name="stringfield2"     type="VARCHAR"/>
    <field name="datefield1"       type="DATE">
        <param name="inputformat"  value="dd/MM/yy"/>
        <param name="outputformat" value="yyyy-MM-dd"/>
    </field>
  </structure>

  <!-- WHAT GRAMMAR USE -->
  <grammar class="net.sf.csv2sql.grammars.mysql.GrammarFactory"/>

  <!-- RENDERER CONFIGURATION -->
  <render class="net.sf.csv2sql.renders.SqlInsertRendererFromExcel">
    <param name="inputfile"     value="users.xls"/>
    <param name="rowcount"      value="4"/>
    <!--optional-->
    <param name="trimdata"       value="true"/>
    <param name="suppressheader" value="false"/>
  </render>

  <!-- WRITER CONFIGURATION -->
  <output>
    <writerAppender active="true"
        class="net.sf.csv2sql.writers.StandardOutputWriter">
    </writerAppender>
  </output>


</root>

