Link Search Menu Expand Document

How to parse table without borders

Step by step guide:

This guide is made for borderless table. The template in this tutorial is based on the table image below. You can get the template here.

documentParserTableWithoutBorders

  1. First, create a new Document Parser template using the Online Template Editor.

  2. Next, click the Load Test PDF or Image button and select your source file.

  3. Then, click the +Add Objects button.

  4. Select Add TABLE field based on TEXT SEARCH.

  5. Click on the Edit Template button and look for the table object.

  6. Replace the tableProperties with the following:

"tableProperties": {
          "start": {
              "expression": "Product CodeItem Name",
              "regex": true
          },
          "end": {
              "expression": "Total",
              "regex": true
          },
          "row": {
              "expression": "(?<code>)(?<item>)(?<options>)(?<qty>)(?<price>)(?<subtotal>)",
              "subExpression1": "(?<item>)(?<options>)",
              "subExpression2": "(?<options>)",
              "regex": true
          },
          "columns": [
              {
                  "name": "code",
                  "dataType": "string"
              },
              {
                  "name": "item",
                  "dataType": "string"
              },
              {
                  "name": "options",
                  "dataType": "string"
              },
              {
                  "name": "qty",
                  "dataType": "integer"
              },
              {
                  "name": "price",
                  "dataType": "decimal"
              },
              {
                 "name": "subtotal",
                 "dataType": "decimal"
              }
        ],
        "multipage": true
}
  1. Run the template and output will look like below.

documentParserTableWithoutBordersResult