Databases for testers
Behind the screen sits a database. Learn its tables, rows and keys so you know what the app really stored and what a fault there looks like.
L1–L4 are part of the Pro pass
L0 Explain simply
Analogy: a stack of filing cabinets. Each drawer has a label and holds one kind of form. Every form in a drawer has the same boxes. Every form has its own number, so you can find it again.
Daily List is a to-do list app. Lily adds a task and sees it on the screen. Tom, the tester, asks where that task went. It went into a database.
What it is: A database is an organised store of data that an app reads and writes. These examples use a relational database. (Structured Query Language) asks its tables questions or changes their rows. A table is a grid in the database. Each row is one item, such as one task, and each column is one fact, such as the title. A names one row, and a view is the easy mix-up, because a view is a saved question while a table holds the stored rows.
Why it matters: Without a look inside the database, Tom can only trust the screen. The screen can say Saved when no row was stored. It can also hide a second copy of a task. Tom reads the tables so a has proof.
The cabinet picture stops at size. A database can hold a huge number of rows, and many people can change them at the same moment.
(SYNTHETIC / TRAINING ONLY: Daily List and every person named in this lesson are invented.)
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 Seeing the data store behind the screen as tables with rows, columns and keys.
- A drawer is a table
- A form is a row
- The form number is the key
HOW THE PICTURE MAPS
| In the picture | In the software |
|---|---|
| Filing cabinet | Database |
| Drawer | Table |
| Form | Row |
| Form number | Primary key |
WHERE THIS PICTURE STOPS
- A paper drawer sits in one place. A database can have many people changing rows at once.
- A form number is written once. A key is checked by the database.
- Cabinets do not link their forms. Tables do, through foreign keys.
HOOK
Drawer, form, number.
REMEMBER IT THIS WAY
A contrast: two neighbours told apart by one test.
A row is one whole task; a column is one detail, such as the due date, across the table. The key picks the row.
| In the trick | What it stands for |
|---|---|
| row | One form, such as one task |
| column | One box, such as the title or the due date |
| key | A value that no other row in that table shares |
TELL A FRIEND
A stack of filing cabinets with labelled drawers, one kind of form in each drawer. A database has tables full of rows.
OFTEN MIXED UP WITH How the web works, for testers. The web lesson shows how a request reaches the app. This lesson shows where the app keeps the data.
PRACTISE AND KEEP
Sources for this topic — 9 sources
- Market practice
PostgreSQL foreign key (Devart blog) ↗ — Devart · A foreign key links a column in a child table to the primary key of a parent table so rows cannot point at a missing parent (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. 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.
- Market practice
PostgreSQL transaction (Neon PostgreSQL tutorial) ↗ — Neon · A transaction groups statements so that all are kept or all are undone (search excerpt, page not opened)
Found through a web search; the page was not opened (search excerpt, page not opened). Version: Web page, no edition number. 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.
- Market practice
ISTQB Certified Tester Foundation Level Syllabus v4.0.1 ↗ — International Software Testing Qualifications Board · Test levels and test types name where checks happen, including checks of stored data (confirmed against the syllabus, read in full text from a mirror copy of the publisher PDF, v4.0.1, 15 September 2024)
v4.0.1 is dated 15 September 2024 and is a list of corrections to v4.0 (21 April 2023) that reworded six learning objectives — not a cosmetic reissue. 78 pages.
Two traps this entry exists to stop. v4.0.2 is the German edition (1 March 2025, 94 pages), so sorting by version number reaches the wrong document. And the widely-repeated per-chapter question allocation "8 / 5 / 4 / 11 / 9 / 3" is wrong: it is 8 / 6 / 4 / 11 / 9 / 2, derived from three official sample-exam answer keys and confirmed against the Exam Structure Tables.
The single most consequential detail for a question bank: white-box coverage — statement and branch — is K2 "Explain", not K3 "Apply" (FL-4.3.1, FL-4.3.2, FL-4.3.3), and MC/DC, path and condition coverage are declared out of scope in §4.3. A question asking a candidate to compute branch coverage is testing something this syllabus does not.
Read through a mirror, because the publisher's own domain could not be fetched (a reachability gap, not a statement about the publisher). A 403 there is a policy refusal and says nothing about whether the document exists or is reachable elsewhere.
Anyone on an unrestricted network should open the canonical URL above and confirm the section and page numbers cited against it. Every claim drawn from this entry is written so that it can be checked against a numbered page.
Read from two independent PDF-to-markdown conversions mirrored on raw.githubusercontent.com. They are treated as faithful because they were produced by unrelated parties with different tooling, agree on the full 64-item objective set including wording, and reproduce the same internal inconsistency present in the source PDF. Chapter 1 reads "testware that supports" where Appendix B reads "that support". A conversion artefact does not replicate across two toolchains.
The licence permits attributed non-commercial extracts and use as the basis for articles. Whether a site that sells a pass may rely on that is an owner's decision, not this entry's.
7 November 2026 review: actual publisher PDF 4.0.1, 15 September 2024, 78 pages, front matter/copyright and relevant numbered operative sections 0.5–0.10 and chapters 1–6 compared with CTFLpractice lessons. Earlier mirror/search descriptions are historical access records. TheK2 white-box objectives require explanation; the source does not justify a categorical ban on small numeric illustrations that support explanation. Later Exam Rules 1.2§4.1.4 usesK2 for keyword definitions, while syllabus§0.5 usesK1; keep dated scopes distinct. No copied questions or figure assets.
- Market practice
Transactions (PostgreSQL tutorial) ↗ — PostgreSQL Global Development Group · Method from search excerpts: oneuptime stored-procedure tests, nolongerset B-BEAR, SQLServerCentral 'How to Test Triggers' (search excerpts, pages not opened). Not run against a real procedure in this sweep.
PostgreSQL18 publisher documentation opened on6November2026: §3.4 explicit transactions and savepoints. No execution on PostgreSQL is claimed; engine-specific examples remain scoped to18.
- Market practice
How to write unit tests for MySQL stored procedures (OneUptime) ↗ — OneUptime · Method from search excerpts: oneuptime stored-procedure tests, nolongerset B-BEAR, SQLServerCentral 'How to Test Triggers' (search excerpts, pages not opened). Not run against a real procedure in this sweep.
Found through a web search; the page was not opened (search excerpt, page not opened). 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.
- Market practice
B-BEAR: quick and dirty SQL Server testing ↗ — No Longer Set · Method from search excerpts: oneuptime stored-procedure tests, nolongerset B-BEAR, SQLServerCentral 'How to Test Triggers' (search excerpts, pages not opened). Not run against a real procedure in this sweep.
Found through a web search; the page was not opened (search excerpt, page not opened). 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.
- Market practice
How to Test Triggers? (forum thread) ↗ — SQLServerCentral · Method from search excerpts: oneuptime stored-procedure tests, nolongerset B-BEAR, SQLServerCentral 'How to Test Triggers' (search excerpts, pages not opened). Not run against a real procedure in this sweep.
Found through a web search; the page was not opened (search excerpt, page not opened). 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.
- Implementation-specific
PostgreSQL documentation ↗ — The PostgreSQL Global Development Group · PostgreSQL 18 official manual, opened 2026-11-06: tutorial-start, ddl-constraints, tutorial-transactions and sql-createview. Supports only PostgreSQL behavior; earlier execution evidence remains separately versioned.
An implementation, not the standard — which is the point. ISO/IEC 9075-2 is paywalled, and this documents the same constructs in text anybody can open. Its isolation-level chapter attributes to the standard explicitly, so it can carry a standard-level claim as long as the citation says which document it is quoting.
Cited as market practice rather than an official standard by kind: an engine's manual is authoritative about that engine and is not the obligation. Where a question turns on behaviour PostgreSQL chose rather than behaviour SQL requires, the answer has to say so.
One correction carried here because it circulates widely: the sentence "The fundamental difference between WHERE and HAVING…", quoted all over the internet as PostgreSQL documentation, is not in the current documentation. It was searched for in the source tree and is not there.
Read through a mirror, because the publisher's own domain could not be fetched (a reachability gap, not a statement about the publisher). A 403 there is a policy refusal and says nothing about whether the document exists or is reachable elsewhere.
Anyone on an unrestricted network should open the canonical URL above and confirm the section and page numbers cited against it. Every claim drawn from this entry is written so that it can be checked against a numbered page.
Read from the
postgres/postgresdocumentation source tree (doc/src/sgml), which the project itself maintains and which carries the section ids the published URLs are derived from — so a cited section id can be checked against the rendered page. - Implementation-specific
SQLite official documentation — constraints, types and transactions ↗ — SQLite · SQLite rolling official documentation, opened 2026-11-06: foreignkeys.html, datatype3.html, lang_createtable.html, lang_transaction.html, isolation.html, cli.html, series.html and lang_createtrigger.html as relevant. Historical SQLite 3.40.1 results remain distinct from in-memory audit witnesses on 3.53.1.
Relevant primary pages opened 6 November2026; rolling documentation and CLI examples (3.54.0) are distinct from historical lesson runs3.40.1 and audit witnesses3.53.1. No file/connected database audit execution.
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.