DATA JOURNALSQL, models & data integrity

Make the data
explain itself.

A data engineering notebook about rows, keys, time and evidence. Small examples make the rules inspectable before they reach a larger pipeline.

Working note / 001TABLE GRAIN

One row means one thing.

Start with the identity of a record. Then write the query that checks it.

Illustrative staging rows
source_keyrevisionamount
A-101112.00
A-10217.50
A-101213.00
The useful questionIs the grain an entity, or a version of that entity?
Declare the grain
Rows. Rules. Evidence.6 original data studies

Models, SQL examples and validation methods

Notes from the data desk

Browse the archive
Reconciliation

Reconcile at the Same Grain

Align population, units and reporting boundaries before comparing totals, and keep missing keys distinct from value differences.

5 min readRead article

Questions under study

Four questions behind the tables

Methods index

An editorial record

Publication updates

Full update log
  1. Established the Orabl notebook

    Defined a standalone editorial scope covering SQL, modeling and data integrity.

  2. Declared the first modeling rules

    Added the distinction between row grain, entity identity and record version.

  3. Added the join cardinality study

    Outlined small checks for row multiplication and reference coverage.

  4. Wrote the data contract guide

    Documented null, key, reference and failure policies for a pipeline stage.

Documented work, with its current stage

Studies

View the index

GrainMap

Design study

A model-review notebook that records table grain and tests key and join assumptions using small fixtures.

  • SQL
  • Keys
  • Model documentation
Updated October 3, 2026Read the project note

Checkset

Contract documented

A data contract design defining quality checks, affected populations and the response to a failed condition.

  • SQL checks
  • Constraints
  • Quarantine
Updated October 3, 2026Read the project note

ReplayLane

Test design

A batch ingestion protocol with immutable inputs, conflict rules and an explicit replay exercise.

  • PostgreSQL
  • Transactions
  • Batch manifests
Updated October 3, 2026Read the project note

LedgerDiff

Method documented

A reconciliation method that retains coverage gaps and signed value differences at a declared comparison grain.

  • SQL
  • Decimal arithmetic
  • Time windows
Updated October 3, 2026Read the project note