Voluntary organisations per kommune
Atlas view
Voluntary organisations per kommune
api_v1.kommune_ngo_summaryActive voluntary organisations per kommune and ICNPO category.
Built from
This Atlas view joins data from the following upstream sources. Click through for provenance, methodology, and citation.
Atlas internal model ↗
dim_brreg_enhet
Current state of every organisation registered in Norway — the whole of Brønnøysundregistrene's Enhetsregisteret, ~1.17M rows, reconciled from the bulk snapshot (PLAN-001) plus…
Atlas internal model ↗
dim_kommune
Canonical kommune dimension.
Showing direct dbt parents. See full lineage in /lineage/ →
Columns
| Column | Description |
|---|---|
| kommune_nr | 4-digit kommune code. FK to dim_kommune. |
| kommune_name | Kommune name in bokmål, joined from dim_kommune. |
| icnpo_nummer | ICNPO category number as Brreg assigns it. NULL where the organisation carries no ICNPO classification. |
| icnpo_kategori | ICNPO category label. NULL where the organisation carries no ICNPO classification — those rows are counted, not dropped, so a per-kommune total over this view stays correct. |
| active_count | Count of organisations in this kommune and category that are both is_active and registrert_i_frivillighetsregisteret. Always >= 1; absent combinations mean zero. |
Sample query
Live PostgREST query that returns the first 5 rows. URL adapts to the current host — local dev shows api-atlas.localhost; the deployed site shows the configured API base.
https://api-atlas.urbalurba.com/kommune_ngo_summary?limit=5
About this view
Active voluntary organisations per kommune and ICNPO category.
Active voluntary organisations per kommune and ICNPO category —
the number a consumer previously had to download the whole
register to compute. Published as api_v1.kommune_ngo_summary.
PostgREST has aggregates disabled, so `?select=count()` returns
400 and the only alternatives were ~15 minutes of per-kommune
probes or a 2.8 MB CSV on every page load. One consumer shipped
the download (urb-agents #1250, finding 1); this replaces it with
~12 000 rows.
⚠️ Counts here will NOT match a count over brreg_enhet. 7 488 of
72 792 active voluntary units (10.3 %) carry no kommune_nr — that
is what Brreg publishes — and cannot be attributed to a
municipality. A handful more sit on codes outside the 357 active
kommuner and are dropped by the join.
A (kommune, category) pair absent from this view has zero
organisations; rows are not emitted for empty combinations.
⚠️ CHANGED 2026-09-21: SSB's 9999 'Uoppgitt' is no longer
included. It is a current code, so `is_active` never excluded it,
and this relation had been reporting a place that does not exist.
Counts drop by that row. `dim_kommune` still carries 9999 — the
dimension mirrors SSB's list — and the value is published in
`unattributed_totals` (urb-agents #1301).
⚠️ COST, AND ONE LOAD-BEARING DEPENDENCY. Measured end-to-end
against the live API: 0.12 s filtered by kommune_nr, 0.205-0.326 s
unfiltered for all rows. Before the covering index on
dim_brreg_enhet it was 25 s cold for a 24 kB response and one
request timed out. That index is not an optimisation — drop it and
this relation is unusable rather than slow.