Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 13 Next »

Table of contents:

 Click here to expand the 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 ActionTablesTable 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?

As a column number, you can use either numbers (numbering from zero!), Or, as in Excel, uppercase letters of the Latin alphabet!

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.

 Example

Put all column B values from Table 1 into List 1

Table 1

Before processing

After processing

The specified column values are not removed 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.

 Example

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

Table 1

Before processing

After processing

Variables

The variable peremennay_3 is empty because the table contains only columns A and B


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.

 Example

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

List 1

Table 1

Before processing

After processing

Values are not removed from the list


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

The line will be added to the end of the table

If you need to add several lines to a table at once, you should use the Text Processing-To Table action.

 Example

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.

 Example

Add text and specified cell

Table 1

Before processing

After processing

Lines are always appended to the end of the table


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.

The variable will always contain only a digital value

 Example

Get the number of columns of Table 1 into a variable

Contents of Table 1

We get the result into the column_count variable


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.

The variable will always contain only a digital value

 Example

Get the number of rows of Table 1 into a variable

Contents of Table 1

We get the result into the line_count variable


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.

 Example

Bind table 1 to a given file

Table 1 will be linked to the corresponding file


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.

 Example

Get into a variable the value from cell B2 of table 1

Table 1 content

After executing the action, we get the result into the yacheika variable


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 .

 Example

Sort in descending order the values of all columns of table 1

Table 1

Before processing

After processing


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.

The function has the option to only overwrite the file

 Example

Save table 1 values to a file

Table 1 content

After execution, all values will be written 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.

 Example

Remove all takes in table 1

Table 1

Before processing

After processing


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.

The column will be deleted with all values

 Example

Remove column B from table 1

Table 1

Before processing

After processing


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

The given row will be deleted in all columns

 Example

Remove the third line from table 1

Table 1

Before processing

After processing

The third line has been deleted entirely


Guidelines for working with tables

It must be strictly observed for the projects to work correctly

  • 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.


  1. Table

  2. Google Sheets

  3. List

  4. List processing

  5. Project variables

  6. Regular Expression Tester

  7. Value ranges

  • No labels