Table Tree

The Table Tree is an input specification for uploading tables to 1010data.

The overall format of the Table Tree is as follows:

<table name="table name">
  <title>table title</title>
  <totals>for tabulations</totals>
  <sdesc>short description</sdesc>
  <ldesc>long description</ldesc>
  <link>link header</link>
  <maxdown>download limit</maxdown>
  <cols>
    <th name="name of first column"
    type="data type of first column"
    format="data format of first column">
    heading of first column
    </th>
    <th name="name of second column"
    type="data type of second column"
    format="data format of second column">
    heading of second column
    </th>

    ...

    <th name="name of last column"
    type="data type of last column"
    format="data format of last column">
    heading of last column
    </th>
  </cols>
  <data>
    <tr>
    <td>value of first row of first column</td>
    <td>value of first row of second column</td>

    ...

    <td>value of first row of last column</td>
    </tr>
    <tr>
    <td>value of second row of first column</td>
    <td>value of second row of second column</td>

    ...
    
    <td>value of second row of last column</td>
    </tr>

    ...
    
    <tr>
    <td>value of last row of first column</td>
    <td>value of last row of second column</td>

    ...
    
    <td>value of last row of last column</td>
    </tr>
  </data>
</table>

For example, consider the following table:

This table can be represented by the following table tree:

<table>
  <title>Table Tree Example</title>
  <sdesc>Example of a table tree</sdesc>
  <cols>
    <th name="transid" type="i">Transaction ID</th>
    <th name="store" type="i">Store</th>
    <th name="sumsales" type="f" format="type:currency">Sum of&#10;Sales</th>
    <th name="totunits" type="f" format="type:num;width:4;dec:0">Total Units</th>
  </cols>
  <data>
    <tr>
      <td>531</td>
      <td>1</td>
      <td>-5</td>
      <td>-1</td>
    </tr>
    <tr>
      <td>532</td>
      <td>1</td>
      <td>1.6</td>
      <td>2</td>
    </tr>
    <tr>
      <td>534</td>
      <td>1</td>
      <td>8.25</td>
      <td>3</td>
    </tr>
    <tr>
      <td>535</td>
      <td>2</td>
      <td>3.85</td>
      <td>3</td>
    </tr>
    <tr>
      <td>536</td>
      <td>2</td>
      <td>6.02</td>
      <td>4</td>
    </tr>
    <tr>
      <td>537</td>
      <td>3</td>
      <td>10.35</td>
      <td>6</td>
    </tr>
    <tr>
      <td>538</td>
      <td>1</td>
      <td>6.95</td>
      <td>8</td>
    </tr>
    <tr>
      <td>539</td>
      <td>2</td>
      <td>5</td>
      <td>1</td>
    </tr>
    <tr>
      <td>540</td>
      <td>2</td>
      <td>1.44</td>
      <td>2</td>
    </tr>
    <tr>
      <td>541</td>
      <td>3</td>
      <td>10</td>
      <td>7</td>
    </tr>
    <tr>
      <td>543</td>
      <td>1</td>
      <td>11.39</td>
      <td>9</td>
    </tr>
  </data>
</table>

The component elements are described in detail in the following sections. Not all components are used in all transactions. See the description of a transaction for information as to which components are relevant to that transaction.