Fill Missing

Put a value in the blank cells of one column. Copy it from a neighbour row, or type it yourself.

What it does

Fill Missing works on one column. It only touches cells that are empty. Cells that hold a value stay as they are.

You choose one of three methods.

MethodWhat it puts in the blank cell
literalA value that you type.
forwardThe nearest value above the blank cell.
backwardThe nearest value below the blank cell.

Fill the blanks

  1. Type fill in the Search transforms box, in the Pipeline panel.
  2. Select Fill Missing in the results.
  3. Open Select column. Pick the column with the blanks.
  4. Open Method. Choose literal, forward, or backward.
  5. For literal, type the value in Fill value (for literal).
  6. For forward or backward, set Sort by (for forward/backward). This step is optional.
  7. Click Apply.

The panel hides the fields you do not need. The value box only appears for literal.

Forward fill on a meter log

A logger writes the meter name once, then leaves it blank:

reading_atmeterkwh
09:00M-124.1
09:154.4
09:304.2
09:45M-131.8

Forward fill on meter, sorted by reading_at, gives this:

reading_atmeterkwh
09:00M-124.1
09:15M-124.4
09:30M-124.2
09:45M-131.8

Two blank cells in a row both got M-12. Forward fill carries a value through a whole run of blanks.

Row order decides the result

Forward fill reads upward. Backward fill reads downward. Both depend on the order of your rows.

Leave Sort by (for forward/backward) empty and the current row order applies.

Set a sort column and the fill follows that order instead. Pick a date or a sequence number.

Tips

  • Blanks at the top cannot be filled forward. Nothing sits above them. Use backward for those.
  • A literal value converts to the column type. Type 0 for a number column, not zero.
  • A value that does not convert leaves the cell empty. N/A in a number column fills nothing.
  • The column keeps its position in the grid.
  • Check your work with Filter and the is Empty comparison.

For SQL users

A literal fill on a text column runs as:

SELECT "reading_at", "kwh", COALESCE("meter", 'unknown') AS "meter" FROM "meter_log"

Forward and backward fills use LAST_VALUE or FIRST_VALUE with IGNORE NULLS.

Try Fill Missing with sample data →

Related Operations

  • Join - Join with another file/table
  • Unnest - Explode delimited column into rows
  • JSON Extract - Extract data in JSON format into columns