<?xml version="1.0"?>
<serv_op>
  <parameters id="TABLE_DEF_P" _name="Table's description">
    <parameter id="TABLE_NAME" _name="Name" _descr="Table's name" gdatype="gchararray" nullok="FALSE">
      <gda_value>table_name</gda_value>
    </parameter>
    <parameter id="TABLE_TEMP" _name="Temporary table" gdatype="gboolean" nullok="TRUE">
      <gda_value>FALSE</gda_value>
    </parameter>
    <parameter id="TABLE_IFNOTEXISTS" _name="Only if it does not yet exist" _descr="Create table only if it does not yet exist" gdatype="gboolean" nullok="TRUE">
      <gda_value>FALSE</gda_value>
    </parameter>
  </parameters>

  <!-- list of fields -->
  <gda_array id="FIELDS_A" _name="Table's columns">
    <gda_array_field id="COLUMN_NAME" _name="Field name" gdatype="gchararray" nullok="FALSE"/>
    <gda_array_field id="COLUMN_TYPE" _name="Data type" gdatype="gchararray" hint="datatype" nullok="FALSE"/>
    <gda_array_field id="COLUMN_SIZE" _name="Size" gdatype="guint" nullok="TRUE"/>
    <gda_array_field id="COLUMN_SCALE" _name="Scale" gdatype="guint" nullok="TRUE"/>
    <gda_array_field id="COLUMN_NNUL" _name="Not NULL" gdatype="gboolean" nullok="TRUE"/>
    <gda_array_field id="COLUMN_AUTOINC" _name="Auto increment" gdatype="gboolean" nullok="TRUE"/>
    <gda_array_field id="COLUMN_UNIQUE" _name="Unique" gdatype="gboolean" nullok="TRUE"/>
    <gda_array_field id="COLUMN_PKEY" _name="Primary key" gdatype="gboolean" nullok="TRUE"/>
    <gda_array_field id="COLUMN_DEFAULT" _name="Default" _descr="Default value" gdatype="gchararray" nullok="TRUE"/>
    <gda_array_field id="COLUMN_CHECK" _name="Check" _descr="Check constraint" gdatype="gchararray" nullok="TRUE"/>
    <!-- To translators: "Compare method" refers to the method SQLite has to compare values -->
    <gda_array_field id="COLUMN_COLLATE" _name="Compare method" _descr="Collation name (BINARY|NOCASE)" gdatype="gchararray" nullok="TRUE"/>
    <gda_array_field id="COLUMN_CONFLICT" _name="Conflict" _descr="Conflict resolution method (ROLLBACK|ABORT|FAIL|IGNORE|REPLACE)" gdatype="gchararray" nullok="TRUE"/>
  </gda_array>

  <sequence id="FKEY_S" _name="Foreign key">
    <parameter id="FKEY_REF_TABLE" _name="Referenced table" gdatype="gchararray" nullok="FALSE" source="_DICT_TABLES_">
      <gda_value>ref_table</gda_value>
    </parameter>
    <gda_array id="FKEY_FIELDS_A" _name="Fields" _descr="Fields in the foreign key">
      <gda_array_field id="FK_FIELD" _name="Field" gdatype="gchararray" nullok="FALSE"/>
      <gda_array_field id="FK_REF_PK_FIELD" _name="Referenced field" gdatype="gchararray" nullok="FALSE" source="_FKEY_REF_TABLE/DICT_FIELDS_"/>
      <gda_array_data>
        <gda_array_row>
          <gda_value>id_ref</gda_value>
          <gda_value>id</gda_value>
        </gda_array_row>
      </gda_array_data>
    </gda_array>
    <parameter id="FKEY_MATCH_TYPE" _name="Match type" _descr="Matching method if more than one field involved" gdatype="gchararray" nullok="TRUE" source="match_types:0">
      <gda_value>MATCH SIMPLE</gda_value>
    </parameter>
    <parameter id="FKEY_ONUPDATE" _name="On update action" gdatype="gchararray" nullok="TRUE" source="action_cb:0">
      <gda_value>NO ACTION</gda_value>
    </parameter>
    <parameter id="FKEY_ONDELETE" _name="On delete action" gdatype="gchararray" nullok="TRUE" source="action_cb:0">
      <gda_value>NO ACTION</gda_value>
    </parameter>
  </sequence>

  <!-- other table constraints -->
  <sequence id="TABLE_CONSTRAINTS_S" _name="Global constraints">
    <parameter id="CONSTRAINT_STRING" name="Constraint" gdatype="gchararray" nullok="FALSE">
      <gda_value>CHECK (column &gt; 0)</gda_value>
    </parameter>
  </sequence>
</serv_op>
