Field Guide · 07

Naming conventions

A naming convention is compression for context. A good name tells you the layer, the role and the type of a column before you open the table, and a consistent one lets tools and people guess correctly.

Principles

  • Names carry layer, role and type. gold.dim_customer.customer_key says where it lives, what the table is for and what kind of key it is.
  • Predictable beats clever. The best convention is the one a new engineer can apply correctly on day two.
  • One style per surface. snake_case everywhere in the lake and warehouse; friendly names with spaces where business users browse, which means the semantic model.
  • Bronze keeps the source's names. Renaming starts in silver. If bronze renames, you lose the ability to trace a column back to the source by name.
  • Abbreviate only from an agreed list. qty and amt are fine if written down once; cst_rgn_cd is not.
  • Singular entity names. customer, sales_order_line. Pick singular or plural once and never mix.
Rule of thumb

If two people would name the same new column differently under your convention, the convention has a gap. Close it in writing the first time it happens.

Schemas and table prefixes

Use one schema per layer, plus a few utility schemas, and let table names carry their role:

Schema or prefixMeaningExample
bronze. + {source}_{object}Raw landing, origin in the namebronze.erp_sales_order_header, bronze.crm_salesperson, bronze.files_budget
silver. + {entity}Cleaned business entity, no source prefix because it may merge sourcessilver.customer, silver.sales_order_line
gold.dim_Dimensiondim_customer, dim_date
gold.fact_Fact; add the snapshot period when it is a snapshotfact_sales, fact_inventory_daily
gold.bridge_Many-to-many resolverbridge_sales_credit
gold.agg_Pre-aggregated serving tableagg_sales_month_category
stg. or stg_Transient staging, safe to truncatestg.customer
meta.Pipeline config, logs and registriesmeta.load_config, meta.load_log
In Microsoft Fabric

Schema-enabled lakehouses let you use real bronze, silver and gold schemas in one item. The other common layout is one item per layer (a bronze Lakehouse, a silver Lakehouse, a gold Warehouse), which gives cleaner security boundaries and separate deployment. Many teams also prefix Fabric item names by type (LH_, WH_, NB_, PL_, SM_) so the workspace list sorts itself and deployment pipelines are easier to read.

Column names

Keys and identifiers

  • _key is a surrogate key owned by the warehouse: customer_key, order_date_key.
  • _id is a business or natural key from the source: customer_id, product_id.
  • _number is a human-facing identifier, often a degenerate dimension: order_number, line_number.
  • Role-playing keys put the role first: order_date_key, ship_date_key.

Dates and times

  • _date for a calendar date with no time: order_date, ship_date.
  • _at for a timestamp: modified_at, _ingested_at. Store timestamps in UTC by default.
  • Add _utc or _local only when both exist on the same table: shipped_at_utc beside shipped_at_local.
  • Validity ranges use valid_from and valid_to, with valid_to exclusive.

Booleans, measures and units

  • Booleans start with is_ or has_: is_current, is_month_end, has_returns. Never a bare flag or active.
  • Money ends in _amount (net_amount, cost_amount), quantities in _qty or quantity, counts in _count, ratios in _pct or _rate.
  • Put units in the name when they are ambiguous: weight_kg, lead_time_days.

System and audit columns

Columns added by the platform rather than the business get a leading underscore: _ingested_at, _batch_id, _source_file. The underscore sorts them together, signals "do not put this in a report," and makes it trivial to exclude them when generating silver column lists. Modeling columns that carry business meaning (valid_from, is_current, row_hash) do not get the underscore.

Names in the semantic model

The model is where names become user interface, so the rules change:

  • Tables are plain nouns without prefixes: Sales, not fact_sales; Customer, not dim_customer.
  • Columns are Title Case with spaces: Customer[Customer Name], Sales[Net Amount]. Key columns are renamed too (Customer[Customer Key]) and then hidden.
  • Measures use business language, never "Sum of". Suffixes are consistent: Net Sales PY for prior year, YoY % for growth, % only on ratios (Margin %).
  • No column and measure share a name. Hide Sales[Net Amount] and expose the measure Net Sales, so authors cannot drag the wrong one.
  • Rename at the model boundary, not with views. Model column names can differ from the source column names, which keeps gold clean and avoids views that would push Direct Lake on the SQL endpoint into DirectQuery fallback.
  • Write descriptions and synonyms. Copilot and data agents use them to map a question to a measure, so names and descriptions are now part of the query interface, not just documentation.

One column, end to end

Following a few columns through every layer shows the convention doing its job. Source column names are illustrative.

SourceBronzeSilverGoldSemantic model
erp.sales_order_line.NetAmtNetAmtnet_amount (derived: gross less discount)fact_sales.net_amountSales[Net Amount] (hidden), measure Net Sales
erp.customer.CUSTNOCUSTNOcustomer_iddim_customer.customer_id plus customer_keyCustomer[Customer ID]; Customer[Customer Key] hidden
erp.sales_order_header.ShipDtShipDtship_datefact_sales.ship_date_keyInactive relationship; measure Sales by Ship Date
none_ingested_at, _batch_idCarried for lineageUsually dropped, or kept as _loaded_atNot imported

Conventions that cause trouble

  • Reserved words as column names (date, order, user, value) force quoting in every engine. dim_date uses calendar_date for this reason.
  • Spaces and special characters in lake column names need Delta column mapping and break some readers. Keep them out of the lake entirely.
  • Case. Spark resolves column names case-insensitively by default. Fabric Warehouse defaults to a case-sensitive collation, which affects string comparisons and, by default, identifiers; a case-insensitive collation can be chosen when a warehouse is created. VertiPaq compares text case-insensitively, so two business keys that differ only by case collapse into one in the model.
  • Encoding meaning in prefixes nobody maintains (Hungarian-style str_, int_) adds noise without information once types are visible in every tool.
Open question

Schemas in one lakehouse or one item per layer? Schemas keep cross-layer queries simple; separate items give cleaner permissions and deployment. The deciding factor is usually whether different people are allowed to read bronze and gold.

See it

The Column lineage tracer follows each sample column from source name to model name, which is the quickest way to spot a convention being broken.