Skip to content
Legacy docs for Tenzir v5.x. For the latest Tenzir v6 series, visit docs.tenzir.com. Migrating from v5? Read the Tenzir v6 migration guide.

Extracts the month component from a timestamp.

month(x: time) -> int

The month function extracts the month component from a timestamp as an integer (1-12).

The timestamp from which to extract the month.

from {
ts: 2024-06-15T14:30:45.123456,
}
month = ts.month()
{
ts: 2024-06-15T14:30:45.123456,
month: 6,
}

Last updated: