> AI agents: this is one page from Mammoth Analytics documentation. The index of all pages as Markdown is https://mammoth.io/docs/llms.txt. Append `.md` to any docs URL, or send `Accept: text/markdown`, to get Markdown.

# Label rows, edit cells and fill blanks in Mammoth

> Label rows by condition with Label & Insert Values, edit single cells in the Mammoth grid, stamp a load date, and fill empty cells from the rows around them.

The **Label & Edit** group in **Describe your transformation** > **Filter, Label & Replace** has three tasks. **Label & Insert Values** writes a value into all rows or only rows that match a condition. **Edit Cells** lets you type corrections straight into the grid. **Fill Missing Values** fills empty cells from nearby rows or predicted values.

## Label rows that meet a condition

**Label & Insert Values** inserts a value into every row, or only into rows that match a condition.

![Label & Insert Values panel with value 10 applied to Some cells, a condition on hotel_name, and result column Product_unit](https://mammoth.io/docs/images/20260511_165151_Screenshot2026-05-061639031.webp)

1. Open **Label & Insert Values**.
2. In **Enter a value**, type the value. The input adapts to the type of the column you write into. To insert a parameter's value, click the **Val** chip and choose **Parameter**; only parameters of the column's type are listed.
3. Choose **All cells** or **Some cells**.
4. For **Some cells**, click **Add Condition**. In the condition dialog, describe the condition in natural language or build it with column and operator dropdowns. A **Condition added** chip then shows the condition, with edit and delete icons.
5. In **Place in new column**, keep **New** and type a column name and type, or click the word **new** and choose **Existing** to pick a column.
6. Click **Apply**.

### Insert different values for different rows

Click **Add another value** to insert a different value into other rows in the same task. Each earlier value needs a condition (**Some cells**); the last value then applies to **All remaining cells**. Drag values to reorder them.

![Label & Insert Values panel with value 100 applied to Some cells under a condition, a second value for All remaining cells, Add another value, and a Place in new column field](https://mammoth.io/docs/images/20261009_120200_LabelInsertValues-TwoValues.webp)

For example, to tag orders by size, insert `Large` into **Some cells** where `order_amount` **is greater than** 1000, then **Add another value** `Standard` for **All remaining cells**, placed in a new column `order_size`.

### Stamp rows with the current date or time

When the result column is a Date column, the value is a dropdown with three options:

| Option | What it inserts |
| --- | --- |
| **Datetime** | A fixed date and time you pick in the **Choose date time** picker, to the second. It never changes. |
| **Current Date UTC** | The UTC date the step runs, at midnight (00:00:00). |
| **Current Time UTC** | The UTC date and time the step runs. |

**Current Date UTC** and **Current Time UTC** are worked out again on every run, including scheduled runs and reruns. Use them to stamp rows with a load date or a "last refreshed" time. Every row the step writes gets the same value in a given run.

### Label values from an Explore card

Click the three-dot menu on any value bar in an Explore card and choose **Replace all values like this**. Label & Insert Values opens with that value set as the condition, so it targets only rows with that value. See [Explore cards](https://mammoth.io/docs/learn/explore/explore-cards/).

You can also open **Label & Insert Values** from a column's 3-dot menu, with that column pre-selected.

## Edit individual cells in the grid

**Edit Cells** is for one-off corrections where a rule would be overkill.

![View in Editing the grid mode, with a blue header bar offering Discard changes and Apply changes beside an Edit Cells task](https://mammoth.io/docs/images/20260417_123829_Viewin_Editingthegrid_modewiththeblueheaderbar1.webp)

1. Choose **Edit Cells** in the Transform menu, or double-click a cell. If cell editing is off for the dataset, a dialog asks you to turn it on first (see below).
2. The View enters **Editing the grid** mode, with a blue bar at the top offering **Discard changes** and **Apply changes**.
3. Double-click a cell and type the new value. Edited cells are highlighted.
4. Check the task card in the Pipeline panel. It lists every edit as Original → New, each with an X to remove that change.
5. Click **Apply changes** (or **Add to Pipeline** in Draft mode) to save all edits as one pipeline task, or **Discard changes** to cancel.

Edit Cells tasks can't be copied or duplicated.

### Turn on cell editing for a dataset

Cell editing is a dataset setting and is off by default. It is meant for datasets under 500K rows.

From the dataset's settings in the Data Library:

1. Open the dataset in the Data Library and go to its settings.
2. Click the **Cell editing** switch (it shows On or Off).
3. Mammoth asks "Turn on cell editing?" and notes that it "Re-runs this dataset's pipelines once, and stays on until every edit task is removed."
4. Click **Turn on**.

From the data editor, double-click a cell, or choose **Edit Cells**. If editing is off, the **Enable Cell Editing** dialog opens. The same dialog opens from **Cell editing** (shown as **Enabled** or **Disabled**) on the dataset settings page that the settings icon at the start of the View tab bar opens. It notes that:

- Enabling cell editing will re-run the pipelines in the dataset.
- It will stay active, and you can disable it only if edit tasks are removed.
- It is recommended for smaller datasets (< 500K rows).

Click **Enable Editing**. While the pipeline re-runs, the blue bar at the top reads "Enabling cell editing while the pipeline re-runs". If it stops, the bar reads "Enabling cell editing did not finish", with a **Try again** button. When it's ready you see "Cell editing is now enabled. Double-click a cell to begin editing."

To turn it off, click the **Cell editing** switch again and confirm **Turn off** (on the dataset settings page, **Disable Editing**). This is "Only possible once no cells have been edited, or every edited cell has been removed." See [Dataset settings and history](https://mammoth.io/docs/learn/organise/dataset-settings/).

## Fill empty cells from the rows around them

**Fill Missing Values** fills empty cells in a column.

![Fill Missing Values panel with a column selected, the Directional and Smart fill methods, Above and Below direction, and a before and after preview](https://mammoth.io/docs/images/20261009_132358_FillMissingValues-Directional.webp)

1. In **Select column**, choose the column with empty cells.
2. Choose a **Fill Method**:
   - **Directional** copies the closest value above or below in the column.
   - **Smart** predicts each empty cell from patterns in your complete rows.
3. For **Directional**, choose a **Direction**: **Above** fills each empty cell with the nearest non-empty value above it; **Below** uses the nearest one below.
4. Optional, Directional only: **Add Sort** sets the row order first, which decides what counts as above or below.
5. Optional, Directional only: **Group by** fills only within groups, so a value never spills from one group into another.
6. Check the **Preview** panel, then click **Apply**.

With AI fill, the step takes time to run, so its preview waits for you: "This function takes time to run. Click Run preview to see its result." Click **Run preview**.

For example, a report export lists `region` only on the first row of each block. Choose **Directional**, **Above**, to copy each region down to the empty rows below it.

## Limits

| Limit | Value |
| --- | --- |
| Recommended dataset size for cell editing | Under 500K rows |

## Troubleshooting cell edits and fills

| Symptom | Cause | Fix |
| --- | --- | --- |
| Double-clicking a cell opens **Enable Cell Editing** | Cell editing is off for the dataset | Click **Enable Editing**, or leave it off and use Label & Insert Values |
| Can't turn cell editing off | Some cells are still edited | Remove every edit (or the Edit Cells tasks), then turn it off |
| Fill copied values across groups | No **Group by** set | Add **Group by** so filling stays within each group |
| Fill used the wrong neighbour | Row order isn't what you expect | Use **Add Sort** to set the order |

## Related

- [Filter rows](https://mammoth.io/docs/learn/clean-and-shape/filter-rows/): the operators you can use in a condition.
- [Find and replace values](https://mammoth.io/docs/learn/clean-and-shape/find-and-replace/): replace values by rule rather than cell by cell.
- [Add, split, copy and delete columns](https://mammoth.io/docs/learn/clean-and-shape/manage-columns/): add an empty column to fill.
- [Edit, reorder and copy pipeline tasks](https://mammoth.io/docs/learn/clean-and-shape/manage-tasks/): review or remove an Edit Cells task.
- [Parameters and snippets](https://mammoth.io/docs/learn/organise/parameters-and-snippets/): insert a value you change in one place.

---
Source: https://mammoth.io/docs/learn/clean-and-shape/label-and-insert.md · Updated: 2026-11-08
