TOPIC 36/6222 MINNOT STARTED

Data movement and ETL checks

Follow one batch from its agreed input to its expected output. Use counts, keys, values and repeat checks to find what went missing, doubled or changed.

L1–L4 are part of the Pro pass

L0 Explain simply

Analogy: moving house by lorry. You count five boxes before the trip and five after it. That looks fine. But one box could be missing while another was copied. You also need the labels and the contents, not just the count.

Daily List is a to-do list app. A nightly program sends task data to a report table. Nina, the product owner, uses that table for charts. Leo, the developer, calls this program a .

Tom, the tester, first asks what the report should contain. Does one task become one report row? Are unfinished tasks left out? Are minutes changed to hours? That rule tells him what to test.

Tom then fixes which batch he will check. A batch is the set of data processed in one run. He keeps the input as it was for that run. Comparing yesterday's report with today's changing tasks could make a good copy look wrong.

The box picture has a limit. A pipeline can combine several tasks into one daily total. Then fewer rows can be right. Tom checks what the rule should produce. He does not ask for equal counts in all cases.

(SYNTHETIC / TRAINING ONLY: Daily List and every person named in this lesson are invented.)

PLAIN WORDS · 1 in this section
lorry
a large truck for carrying goods

PICTURE IT

The picture is the one the lesson above opens with. The table below shows how each part of it matches the software.

THE REAL JOB Check one fixed data batch against its expected output, then compare counts, keys, values and repeated rows.

  1. Fix the batch and rule
  2. Count
  3. Compare keys and values
  4. Check repeats
Check the intended batch

HOW THE PICTURE MAPS

How each part of the picture matches the software
In the pictureIn the software
Boxes loaded and taken off the lorryRows in the source and the target
Counting the boxesThe row count check after agreeing which records belong
Opening boxes to lookThe comparison of mapped values, not only keys
A box swapped for a copy of anotherA lost row balanced by a repeated row

WHERE THIS PICTURE STOPS

  • Boxes keep their shape, but a pipeline can filter tasks or combine them into totals.
  • A mover sees a dropped box at once, but data can be lost without any sign.
  • A lorry makes one trip, but a pipeline runs again and again.

HOOK

Fix the batch, count, compare keys and contents.

REMEMBER IT THIS WAY

A contrast: two neighbours told apart by one test.

Equal counts show equal numbers of rows in the chosen scope. Key and value comparisons plus repeat checks test whether the intended output arrived.

What each part of the trick stands for
In the trickWhat it stands for
Countsthe row count check
Comparethe source-to-target comparison

TELL A FRIEND

A mover checks labels and contents as well as the box count. A tester first agrees the batch and intended changes.

OFTEN MIXED UP WITH Checking data after an action. Checking data after actions looks at what one action leaves in the database. This lesson checks a whole copy of data between two places.

Sources & standards — 10 sources
  1. Market practice

    Extract, transform, and load (ETL), Azure Architecture Center ↗ — Microsoft · ETL process and ELT sections: transformations include filtering, aggregation and joins; target grain can differ from source. Relevant primary passage opened 8 November 2026.

    ETL and ELT sections; explains intended data transformations and processing order. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  2. Market practice

    Combining Queries: UNION, INTERSECT, EXCEPT (PostgreSQL documentation) ↗ — PostgreSQL Global Development Group · PostgreSQL 18, section 7.4: EXCEPT compares the selected columns, removes duplicates unless ALL is specified, and requires compatible column counts and types. Relevant primary passage opened 8 November 2026.

    §7.4 UNION/INTERSECT/EXCEPT and ALL. PostgreSQL18 implementation, not a universal SQL mandate. · Checked 2026-11-06

    PostgreSQL18 publisher documentation opened on6November2026: §7.4 UNION/INTERSECT/EXCEPT and ALL. No execution on PostgreSQL is claimed; engine-specific examples remain scoped to18.

  3. Market practice

    PostgreSQL 18 — Aggregate Functions ↗ — PostgreSQL Global Development Group · PostgreSQL 18, section 9.21: COUNT(*) counts rows, COUNT(expression) counts non-null values and SUM uses non-null inputs. Relevant primary passage opened 8 November 2026.

    COUNT(*) counts input rows; COUNT(expression) counts non-null input values. Opened actual aggregate table; examples in curriculum are synthetic fixtures. · Checked 2026-11-06

    Opened relevant primary passages on6November2026 via normal web search and document view. COUNT(*) counts input rows; COUNT(expression) counts non-null input values. Opened actual aggregate table; examples in curriculum are synthetic fixtures.

  4. Market practice

    SELECT: compound select statements (SQLite documentation) ↗ — SQLite project · Compound SELECT: EXCEPT returns distinct left-side rows absent on the right. NULL values compare equal for duplicate removal. SQLite does not offer EXCEPT ALL. Relevant primary passage opened 8 November 2026.

    Says EXCEPT returns the rows from the left query that the right query does not produce, and that both sides need the same number of columns. · Checked 2026-11-06

    SQLite rolling SELECT documentation opened6November2026; §§2–5 joins/grouping/bare columns/compound queries/order/limit. UNION ALL supported; INTERSECT ALL/EXCEPT ALL are not. Synthetic fixtures rechecked on3.53.1; historical3.40.1 observations retain their date/version.

  5. Market practice

    Incrementally load data from a source data store to a destination data store ↗ — Microsoft · Watermark and Change Tracking sections: bounded changed-row loading differs from a change mechanism that exposes inserts, updates and deletes. Relevant primary passage opened 8 November 2026.

    Watermark-based bounded loading and SQL Change Tracking, including deletion information. Does not guarantee late-data or replay handling for every pipeline. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  6. Market practice

    CHECKSUM (Transact-SQL): Remarks and limitations ↗ — Microsoft · CHECKSUM Remarks: changed inputs need not change the result; nvarchar dash characters are ignored. This is SQL Server guidance, not PostgreSQL syntax. Relevant primary passage opened 8 November 2026.

    SQL Server checksum collision and ignored-character warnings. Not a cross-engine checksum contract. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  7. Market practice

    Apache Airflow best practices: Creating a task ↗ — Apache Software Foundation · Creating a task: avoid incomplete output, use the same partition on retries and avoid duplicate-producing inserts. The testing plan is an editorial application. Relevant primary passage opened 8 November 2026.

    Task retries should reuse a defined input partition and produce the same outcome, without incomplete output or duplicate-producing writes. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  8. Market practice

    Kimball University: The Subsystems of ETL Revisited (Kimball Group) ↗ — Kimball Group · Cleaning and conforming subsystems 4–6; late-arriving data handler 16; recovery/restart 24; lineage 29. Practitioner guidance, not a universal testing standard. Relevant primary passage opened 8 November 2026.

    Lists the parts of an extract, transform, load system, including quality screens, error event tracking and an audit record for each load. Practitioner guidance from a well-known data warehouse group, not a standard. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web article, 2007. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  9. Market practice

    Slowly Changing Dimensions, Part 2 ↗ — Kimball Group · Type 2: new dimension record, surrogate key, adjacent effective periods and current flag. Test expectations must follow the chosen history and deletion policy. Relevant primary passage opened 8 November 2026.

    Ralph Kimball, 22 September 2008. Type 2 dimension history, surrogate keys, effective periods and current flag. Practitioner model, not every warehouse design. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  10. Market practicePostgreSQL 18 §9.2 Comparison Functions and Operators

    PostgreSQL 18 §9.2 Comparison Functions and Operators ↗ — PostgreSQL Global Development Group · PostgreSQL 18, section 9.2: IS DISTINCT FROM treats NULL as a comparable value; ordinary comparison returns unknown for NULL. Relevant primary passage opened 8 November 2026.

    IS DISTINCT FROM treats NULL as comparable; ordinary comparisons produce unknown when an input is NULL. · Checked 2026-11-06

    Primary text read6November2026; see domain audit for scope and limits.

PRACTISE AND KEEP

Sources for this topic — 10 sources
  1. Market practice

    Extract, transform, and load (ETL), Azure Architecture Center ↗ — Microsoft · ETL process and ELT sections: transformations include filtering, aggregation and joins; target grain can differ from source. Relevant primary passage opened 8 November 2026.

    ETL and ELT sections; explains intended data transformations and processing order. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  2. Market practice

    Combining Queries: UNION, INTERSECT, EXCEPT (PostgreSQL documentation) ↗ — PostgreSQL Global Development Group · PostgreSQL 18, section 7.4: EXCEPT compares the selected columns, removes duplicates unless ALL is specified, and requires compatible column counts and types. Relevant primary passage opened 8 November 2026.

    §7.4 UNION/INTERSECT/EXCEPT and ALL. PostgreSQL18 implementation, not a universal SQL mandate. · Checked 2026-11-06

    PostgreSQL18 publisher documentation opened on6November2026: §7.4 UNION/INTERSECT/EXCEPT and ALL. No execution on PostgreSQL is claimed; engine-specific examples remain scoped to18.

  3. Market practice

    PostgreSQL 18 — Aggregate Functions ↗ — PostgreSQL Global Development Group · PostgreSQL 18, section 9.21: COUNT(*) counts rows, COUNT(expression) counts non-null values and SUM uses non-null inputs. Relevant primary passage opened 8 November 2026.

    COUNT(*) counts input rows; COUNT(expression) counts non-null input values. Opened actual aggregate table; examples in curriculum are synthetic fixtures. · Checked 2026-11-06

    Opened relevant primary passages on6November2026 via normal web search and document view. COUNT(*) counts input rows; COUNT(expression) counts non-null input values. Opened actual aggregate table; examples in curriculum are synthetic fixtures.

  4. Market practice

    SELECT: compound select statements (SQLite documentation) ↗ — SQLite project · Compound SELECT: EXCEPT returns distinct left-side rows absent on the right. NULL values compare equal for duplicate removal. SQLite does not offer EXCEPT ALL. Relevant primary passage opened 8 November 2026.

    Says EXCEPT returns the rows from the left query that the right query does not produce, and that both sides need the same number of columns. · Checked 2026-11-06

    SQLite rolling SELECT documentation opened6November2026; §§2–5 joins/grouping/bare columns/compound queries/order/limit. UNION ALL supported; INTERSECT ALL/EXCEPT ALL are not. Synthetic fixtures rechecked on3.53.1; historical3.40.1 observations retain their date/version.

  5. Market practice

    Incrementally load data from a source data store to a destination data store ↗ — Microsoft · Watermark and Change Tracking sections: bounded changed-row loading differs from a change mechanism that exposes inserts, updates and deletes. Relevant primary passage opened 8 November 2026.

    Watermark-based bounded loading and SQL Change Tracking, including deletion information. Does not guarantee late-data or replay handling for every pipeline. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  6. Market practice

    CHECKSUM (Transact-SQL): Remarks and limitations ↗ — Microsoft · CHECKSUM Remarks: changed inputs need not change the result; nvarchar dash characters are ignored. This is SQL Server guidance, not PostgreSQL syntax. Relevant primary passage opened 8 November 2026.

    SQL Server checksum collision and ignored-character warnings. Not a cross-engine checksum contract. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  7. Market practice

    Apache Airflow best practices: Creating a task ↗ — Apache Software Foundation · Creating a task: avoid incomplete output, use the same partition on retries and avoid duplicate-producing inserts. The testing plan is an editorial application. Relevant primary passage opened 8 November 2026.

    Task retries should reuse a defined input partition and produce the same outcome, without incomplete output or duplicate-producing writes. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  8. Market practice

    Kimball University: The Subsystems of ETL Revisited (Kimball Group) ↗ — Kimball Group · Cleaning and conforming subsystems 4–6; late-arriving data handler 16; recovery/restart 24; lineage 29. Practitioner guidance, not a universal testing standard. Relevant primary passage opened 8 November 2026.

    Lists the parts of an extract, transform, load system, including quality screens, error event tracking and an audit record for each load. Practitioner guidance from a well-known data warehouse group, not a standard. · Checked 2026-10-18

    Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web article, 2007. Licence terms were not read, so put it in your own words and do not quote it. Open the page and confirm what it says before relying on any detail.

  9. Market practice

    Slowly Changing Dimensions, Part 2 ↗ — Kimball Group · Type 2: new dimension record, surrogate key, adjacent effective periods and current flag. Test expectations must follow the chosen history and deletion policy. Relevant primary passage opened 8 November 2026.

    Ralph Kimball, 22 September 2008. Type 2 dimension history, surrogate keys, effective periods and current flag. Practitioner model, not every warehouse design. · Checked 2026-11-08

    Relevant primary passages opened 8 November 2026. Paraphrased teaching only; synthetic examples and test plans are editorial applications, not publisher incidents. No live provider execution claimed.

  10. Market practicePostgreSQL 18 §9.2 Comparison Functions and Operators

    PostgreSQL 18 §9.2 Comparison Functions and Operators ↗ — PostgreSQL Global Development Group · PostgreSQL 18, section 9.2: IS DISTINCT FROM treats NULL as a comparable value; ordinary comparison returns unknown for NULL. Relevant primary passage opened 8 November 2026.

    IS DISTINCT FROM treats NULL as comparable; ordinary comparisons produce unknown when an input is NULL. · Checked 2026-11-06

    Primary text read6November2026; see domain audit for scope and limits.

Deepest material on this page: L4 — Standards & sources. Where a topic stops short of implementation depth, that is a deliberate coverage decision, not an oversight — see coverage.