Table processing

Table of contents


Description

Tables are used to obtain more complexly organized data than lists (for example, a list of products for an online store, where different data are presented line by line: name, price, description, etc.).

The action is used both when working with Tables and with Google Sheets, but Google Sheets has several unique actions, which are described in the article Google Sheets Operations.


How to add a table to a project?

Before getting started, you need to create a Table or Google Sheets .

How to add an action to a project?

Through the context menu Add Action β†’ Tables β†’ Table processing

Or use smart search .

What is it used for?

  • Working with complex data

  • Adding and Retrieving Table Items

  • Removing Rows, Columns and Duplicates

  • Linking to a file

  • Getting the number of rows and columns

How to work with an action?

Get column

Put the values of the given column into a list

  1. We select the table with which we will work.

  2. We indicate the function.

  3. We set a column or variable.

  4. A list into which we put all the column values.

Put all column B values from Table 1 into List 1

Table 1

Before processing

After processing

List 1


Get lines

Receiving a string with the ability to delete from the table and write to the list, variables.

  1. We select the table with which we will work.

  2. We indicate the function.

  3. String criteria (you can specify a variable):
    a) All
    b) Does not contain text
    c) Not matching regular expression
    d) First
    e) By numbers
    f) Random
    g) Contains text
    h) Matching regex

  4. Remove after getting.

  5. Place the result to a list or variables.

Take random rows from Table 1 and put into variables with deletion.

Table 1

Before processing

After processing

Variables


Add list

Put values from the list into the given column.

  1. We select the table with which we will work.

  2. We indicate the function.

  3. We set a column or variable.

  4. List with values.

Take values from list 1 and put in column D of table 1

List 1

Table 1

Before processing

After processing


Add line

Add a line to the table.

  1. We select the table with which we will work.

  2. We indicate the function.

  3. Insert static text or variable.

  4. Important note

Add a line of your text to different columns.

Table 1

Before processing

After processing


Record cell

Add text to a specific cell.

  1. We select the table with which we will work.

  2. We indicate the function.

  3. We set static coordinates of the cell or through variables.

  4. Insert static text or variable.


Get the number of columns

How many columns does the table have

  1. We select the table with which we will work.

  2. We indicate the function.

  3. The variable to get the result.


Get number of lines

How many lines does the table contain

  1. We select the table with which we will work.

  2. We indicate the function.

  3. The variable to get the result.


Bind to file

Binding a table to a file during project execution.

This action should be used when the file path is not known at the time of the template start and will be calculated only during project execution.

  1. We select the table with which we will work.

  2. We indicate the function.

  3. Select a file or specify a variable containing the path to the file.

  4. If the file is missing in the specified path, Zennoposter will automatically create it.


Read cell

Get values from a given cell

  1. We select the table with which we will work.

  2. We indicate the function.

  3. We set static coordinates of the cell or through variables.

  4. Variable for the result.


Sort

Sort table elements in descending or ascending order.

  1. We select the table with which we will work.

  2. We indicate the function.

  3. Zennoposter will automatically detect the columns containing values and offer a choice.

  4. Use the principle as for numbers (this option will work if the column contains only integer values. If there are fractional numbers, then the column will be sorted according to the principle of rows).

  5. We set the type of sorting in descending or ascending order .


Save to file

Saving a table to a file during project execution

  1. We select the table with which we will work.

  2. We indicate the function.

  3. Select a file or specify a variable containing the path to the file.


Remove duplicates

Removing duplicate values in tables

  1. We select the table with which we will work.

  2. We indicate the function.

  3. Zennoposter will automatically detect the columns containing values and offer a choice.


Delete column

Removes the specified table column entirely

  1. We select the table with which we will work.

  2. We indicate the function.

  3. We set a column or variable.


Delete lines

Removes the given rows in all columns

  1. We select the table with which we will work.

  2. We indicate the function.

  3. String criteria (you can specify a variable):
    a) All
    b) Not containing text
    c) Not matching regex
    d) First
    e) By numbers (numbering from zero!)
    f) Random
    g) Containing text
    h) Containing only space symbols
    i) Matching regex


Guidelines for working with tables

  • Do not bind very large files of hundreds of megabytes to the table without the "Save table changes to file" option, especially if you have little RAM.

  • When using a table linked to one file in multiple templates, use one separator. If in one template the columns are separated through ; , and in the other through - then an error will occur.

  • If the template works in multi-threaded mode and you need each thread to work with its own row, enable the "Save table changes to file" option and take data from the table with deletion after taking it.

  • If all projects only read the file, then there will be no problems. When you use file synchronization, there is one table for all threads and all changes in any thread are displayed in the table.

  • If you do not use file synchronization, then a copy of the table will be created for each thread. In this case, deleting a table row in one thread in other threads will not change the table.

  • Keep in mind that tables in RAM take up much more space than the original file on your hard drive. For example, in RAM, a table based on a 10 MB CSV file in 100 threads without synchronization with the file may take 5 GB. Avoid using lists and tables in "no sync" mode with the file unnecessarily.


Usage example

Collect from the pages the name of the desired products in the list and add them from the list to the table for further use

  1. Loading pages.

  2. We collect the necessary values into a list.

  3. We create a table.

  4. Add an action and specify the function to add a list.

  5. We indicate the list and the column in which we will save the values.


Useful links

  1. Table

  2. Google Sheets

  3. List

  4. List processing

  5. Project variables

  6. Regular Expression Tester

  7. Value ranges