nano SIEM
Search Commands

fillnull

Supported in:Self-hosted

Replace empty values in specific fields with a default, so they group and display cleanly.

Use fillnull to replace null values in your chosen fields with a default. This lets you display or group results that have missing values.

Syntax

... | fillnull [value=<value>] <field> [, <field> ...]
ArgumentDefaultDescription
valueNULLThe replacement text. Quote it if it contains spaces or punctuation.
field—The fields to fill. Name them explicitly (see Notes).

How it works

  • Each listed field's null values become value. Non-null values are kept.
  • The filled field becomes a string, even when it held numbers and value is a number (value=0 yields the text "0"). Apply numeric comparisons or sum() before fillnull, or convert back with tonumber() in eval.

Examples

Count logons per user without losing events that have no user name:

class_uid=3002 | fillnull value="(none)" user.name | stats count by user.name

Show a placeholder for unknown hosts and ports in a connection table:

class_uid=4001 | fillnull value="unknown" src_endpoint.hostname, dst_endpoint.hostname | table time, src_endpoint.hostname, dst_endpoint.hostname, dst_endpoint.port

Group HTTP requests by status, keeping requests with no response code:

class_uid=4002 | fillnull value="no response" http_response.code | stats count by http_response.code

Notes

  • List the fields to fill. A bare fillnull with no field list leaves the results unchanged.
  • fillnull also runs after a nano-side stage (lookup, prevalence, inputlookup, resolve_identity, ai, lateral).

What's next

  • eval: coalesce() and if() for conditional defaults
  • stats: group on the filled fields

On this page