Extracting Tables from HTML

Procedure to extract tables from HTML code.

This procedure is part of the HTML Book. To use this Book, you must first learn it in your agent.

Overview

If you have HTML content containing tables, you can use the following procedure to extract those tables. After extracting a table, you can continue working with the data using Kognitos’ table procedures for further manipulation.

Syntax

1. Providing HTML Directly

Use this syntax when you want to pass the HTML code as text directly in the Playground. The placeholder {html} should be well-formed HTML code containing one or more tables.

the html is "{html}"
get the html's tables

Example

the html is "<html><body><table><tr><th>First Name</th><th>Last Name</th></tr><tr><td>John</td><td>Smith</td></tr></table></body></html>"
get the html's tables

2. Prompting for HTML Input

Use this syntax if you want the system to raise a question that prompts you to provide the HTML manually:

the html
get the html's tables

Here, the html will raise a question asking you to provide the data. For the resolution method, you can select Write in answer and paste your HTML code. After submitting, the automation will continue processing.

Last updated

Was this helpful?