List

Integrations table_list

Read several rows from one of your tables

Overview

The List node reads several rows from a table at once, so a flow can show a menu, a price list, or whatever else you keep there.

How It Works

  1. Pick a table. It does not need a key, so an append-only table works
  2. Choose which columns you want back, up to five
  3. Set how many rows at most
  4. The conversation continues down Found or Empty

Choosing Columns

A list step returns only the columns you choose, defaulting to the ones the table shows in its own rows list. This keeps the reply small: every row it returns is carried in the conversation from then on, so a long description you are not going to print is worth leaving out.

Narrowing It Down

A list can be limited to rows matching one column: the mains rather than the whole menu, or the sizes still in stock. Pick a column, how to compare it, and what to compare it against, which can be a value the conversation collected.

Comparison Matches
is Exactly that value
is not Anything but that value
contains Part of it, for text and dates only
is more than Larger, later, or further down the alphabet
is less than Smaller, earlier, or further up it

Numbers compare as numbers, so 9 is less than 100 rather than after it.

A value that comes out empty matches nothing rather than everything, so a question the visitor skipped does not quietly return the lot. That takes Empty.

Encrypted columns cannot be matched on, for the same reason they cannot be sorted: it would mean decrypting every row to look.

Putting Them In Order

Rows come back newest first unless you choose a column to order by, which is usually what a menu or a price list wants. Which way round is named for what the column holds: oldest or newest first for a date, smallest or largest for a number, A to Z for words. Without a column you are ordering by when a row was added, so oldest first is available too. A column that has since been dropped falls back to newest first rather than failing the step: the rows are still the right rows, only their order is not what was asked for.

How Many Rows

Up to 100, and 25 by default. That is a limit on what one step returns rather than what a table can hold. A chat message that lists a hundred things is not a message anyone reads, and every row returned stays in the conversation for the rest of it.

Output Variable

The rows, in order, ready to loop over:

{{#each variable.rows}}
{{this.name}} {{money this.price}}
{{/each}}

{{variable.count}}

Configuration Fields

Table table_selector Required

The table to read from. It does not need a key.

Columns table_columns

Which columns to return, up to five. Defaults to the ones the table shows in its rows list.

Only rows where table_filter

Optional. Narrows what comes back to rows matching one column. Encrypted columns cannot be matched on.

Order by table_sort

Optional. Newest first when nothing is chosen. Encrypted columns cannot be ordered on.

Most rows to return number

Between 1 and 100.

Output Variables

This node stores its output in a variable that can be referenced in subsequent nodes using the {{variable}} syntax.

{{variable}}.rows array

The rows that came back, newest first

{{variable}}.count number

How many rows came back

Connection Points

Input
Accepts incoming connections from other nodes
✓ Found found
At least one row came back
○ Empty empty
The table had no rows to return
✗ Error error
The rows could not be read

More in Integrations

Request a demo
This form is running on UniversalChatbot.