LogoLogo
About
Tables: v2
  • Home
  • Guides
  • BDK
  • REST API
  • Release Notes
Tables: v2
  • Getting Started
    • Tables Overview
  • Table Creation
    • Create a Table
    • Create a Sample Table
    • Create a Pivot Table
    • Create an Integer Table
    • Create a Table from JSON
    • Create a Table from the Rows
    • Create a Combined Table
    • Create a Merged Table
    • Get a Table from a File
  • Rows
    • Get Row(s)
    • Get Row Count
    • Get Row Number
    • Get Value from Row
    • Group Rows
    • Insert a Row
    • Insert an Empty Row
    • Remove Duplicate Rows
    • Set a Row to JSON
  • Columns
    • Get a Column
    • Get a Column's Values
    • Get a Column Number
    • Get Column Count
    • Get Column Stats
    • Get Column Names
    • Change a Column's Data Type
    • Delete Columns
    • Insert a Column
    • Move a Column
    • Rename a Column
    • Rename Columns
    • Round a Column's Values
    • Update a Column
  • Cells
    • Set a Cell in a Table
  • Conversions
    • Convert CSV to a Table
    • Convert a Table to CSV
    • Convert a Table to Excel
  • Manipulations
    • Clear a Table
    • Combine Tables
    • Copy a Table
    • Extract a Subtable
    • Group a Table
    • Query a Table
    • Sort a Table
    • Split a Table
    • Join Subtables
    • Replace a Value
    • Replace a Value in a Column
    • Transpose a Table
Powered by GitBook
On this page
  • Overview
  • Prerequisite Data
  • Syntax
  • Examples

Was this helpful?

Export as PDF
  1. Manipulations

Group a Table

Groups a table by a specified column and optionally aggregates other columns.

Overview

This procedure groups a table by the values in a specific column, and optionally aggregates other columns. This helps you organize and summarize data into meaningful categories. It's useful when you want to analyze totals, averages, or counts within each group, such as total sales by region or number of employees per department.

Prerequisite Data

These required data elements must be present in the automation before using the procedure.

Data Name
Data Type

the table

Table

Syntax

Below is a line-by-line overview of the automation syntax. Expand each line to learn more.

group the table by

What does it do? Groups the table by the specified column and applies optional aggregation on other columns.

Where does it go? This phrase should be written on a new line.

Does it require input data? ⛔ No — This phrase does not require input data.

Is it required? ✅ Yes — This phrase is required in the syntax.

the other columns are

What does it do? Provides an optional list of columns with aggregation functions to apply. Supported aggregation functions are Sum, Average, and Count. To specify aggregation, list the columns in this format: "'s ". For example: "Salary's Sum", "Name's Count", or "Score's Average". If not specified, a count of rows for each group will be returned.

Where does it go? This phrase should be indented beneath group the table by <thing> with.

Does it require input data? ✅ Yes — List of texts

Is it required? 🌟 No — This phrase is optional in the syntax.

Examples

1. Group by Column with Aggregation

create a table where
    the headers are "Department", "Employee", "Salary"
    the rows are
        "HR", "John Doe", 50000
        "HR", "Jane Doe", 60000
        "IT", "Jim Beam", 70000
group the table by Department with
    the other columns are "Salary's Sum"

2. Group by Column with No Additional Columns

create a table where
    the headers are "Project", "Hours Worked"
    the rows are
        "Project A", 10
        "Project B", 20
        "Project A", 15
group the table by Project

Last updated 16 days ago

Was this helpful?