Systems and records
Dataset interoperability acceptance test: 9 formats, 4 quiet changes
By SourceX Editorial · Updated
10 sections
Short answer
A dataset interoperability acceptance test loads a delivery in every format the buyer will use, compares it cell by cell with a reference copy and replays a business task. On nine renderings of the public Chinook database, all loaded with 15,607 rows and 11 intact relationships, yet 1,337 blanks became NULL, one format renamed all 64 columns, and plain SQL rebuilt only 355 of 412 invoice totals.
Checklist
Dataset interoperability
Key takeaways
- Loading and joining is not acceptance: all nine Chinook renderings passed the row, key and relationship checks that most delivery scripts stop at.
- The consumption format can change meaning: 1,337 empty strings in the reference JSON arrive as NULL in every SQL rendering, and Oracle documents that it treats a zero-length string as null.
- Replay the task in the buyer's own tool: the SQLite files store money as binary floating point, so an exact SQL comparison rebuilt 355 of 412 invoice totals and rounding to cents rebuilt all 412.
- Compare content, not only bytes: one content digest covers the reference and all nine current renderings, while four scripts changed every line with no change in content.
- Pin versions by content: at tag v1.4.5 the prebuilt SQLite files carried every invoice date 12 years early, beside scripts from the same release that were correct.
What does a dataset interoperability acceptance test have to prove?
It has to prove that a delivery means the same thing in every format the buyer will actually load: the same records under the same keys, the same relationships, the same values with the same meaning, and the same answer when a business task is rebuilt from them. A file that opens, a schema that parses and a checksum that matches prove none of that on their own.
The test is narrower than a model benchmark and more useful at the moment of acceptance. It does not promise that training on the data will improve anything. It answers a delivery question: when a supplier ships a reference copy and the buyer consumes a derivative, such as a database load for analysts, a warehouse table or an extract for a training job, does anything change on the way? Most changes are silent, because each target system applies its own rules to blanks, names, numbers and dates.
This page runs that test on a public database published in nine renderings, reports what held and what moved, and turns the results into a manifest and a decision rule a buyer can write into a data request.
Nine renderings of one public database
A fair test needs one dataset that its publisher ships in several consumption formats generated from a single source, so that every difference can be traced to a format rather than to the data. The Chinook sample database fits. Its README describes a digital media store with artists, albums, tracks, invoices and customers; says the media data came from an iTunes library, the customer and employee records are fictitious and the sales were randomly generated over a four-year period; and states that ChinookData.json holds the data, ChinookDataSet.xsd the schema, and text templates generate every SQL script. The repository carries an MIT license.
At commit 7f67772, dated 5 October 2025, the reference JSON holds 11 tables, 15,607 rows and 64 columns. The test compared it with nine renderings: seven SQL scripts, for SQLite, PostgreSQL, MySQL, SQL Server, SQL Server Compact, Oracle and Db2, and two prebuilt SQLite database files. Four of the six further scripts that let the database generate its own keys were checked for key assignment only. Nothing from the repository was executed: a script written for this page tokenized the SQL as text and opened the database files read-only.
A licensed business dataset can travel the same way: one export from the source system, then copies shaped for each consuming team's tools. The records differ from a sample music store; the ways a copy can drift from its source do not.
Eight checks and what each found on Chinook
The matrix below is the test as run: the rule the script applied, the result across all nine renderings at commit 7f67772, and what a failure would mean in a real delivery. Checks 1 to 3 are where most acceptance scripts stop; checks 4 to 8 are where the formats parted.
| Check | Rule as run | Chinook result | A failure would mean |
|---|---|---|---|
| 1. Load and count | Every table read; rows per table compared with the reference | 15,607 rows in all nine renderings, no table short or long | Records lost or duplicated in conversion |
| 2. Keys | Primary keys from the XSD, compound for PlaylistTrack; key sets compared | 0 missing and 0 extra keys in all nine | Joins and deletion requests reach the wrong rows |
| 3. Relationships | Every foreign key the rendering declares, checked against its parent keys | 11 declared in each rendering, 0 unresolved references | Orphaned invoice lines, invoices or tracks |
| 4. Names | Each table and column mapped to its reference spelling | PostgreSQL renames all 11 tables and 64 columns; the other eight match | Code and manifests written for one format break on another |
| 5. Values | 66,439 cells per rendering compared under the normalization rules | 0 differences other than check 6 | Changed facts behind a clean load |
| 6. Blank versus null | Reference empty string compared with the rendering's value | 1,337 blanks arrive as NULL in all nine; the reference has 1 true null | Missing-value counts change with the format |
| 7. Task replay | Invoice total equals the sum of its lines, in exact decimals and in the consumer's own SQL | 412 of 412 in exact decimals; plain SQL in the SQLite files matches 355 | A correct file returns a wrong business answer |
| 8. Version by content | Content digest of parsed rows compared with byte checksums, at tag v1.4.5 and at 7f67772 | One digest across all nine today; the v1.4.5 SQLite files differ | A loadable file from another release |
Same rows, different meaning: blanks, names, dates and keys
Checks 1 to 3 passed everywhere, and that is the trap. Every rendering carried the same 15,607 rows under the same keys, all 11 relationships resolved, no text value exceeded its declared column width in characters or in UTF-8 bytes, and all 412 invoice totals reconciled once values were read as exact decimals. A buyer who stops there accepts four changes that matter.
Blanks became nulls. The reference JSON writes 1,337 empty strings across eight columns, most of them tracks with no composer (977) and invoices with no billing state (202), and exactly one true null: the general manager, who reports to nobody. Every SQL rendering writes all 1,338 as NULL. Oracle's SQL reference says the database currently treats a character value with a length of zero as null and advises against relying on that, so an Oracle consumer cannot store the distinction at all. Whether no composer and an unknown composer are the same fact is a question for the manifest, not for the loader.
Names changed in one format. The PostgreSQL script spells all 11 tables and 64 columns in snake case, so InvoiceLine becomes invoice_line and UnitPrice becomes unit_price. The data is identical, yet a field list, a validation script or a training pipeline written against the reference names fails on that rendering until someone ships a name map.
Dates and types differ in what they can hold. The reference has 428 date values, all at midnight. The PostgreSQL, MySQL, SQL Server and SQL Server Compact scripts write them as year, month and day with no time, the Db2 script declares DATE columns, and the Oracle script wraps each in a TO_DATE call. Nothing was lost only because no value carried a time. The Oracle script also builds 487 text values by concatenation, writing the ampersand as chr(38) and the apostrophe as chr(39); evaluated, they equal the reference, but a plain text comparison flags every one.
Generated keys line up by the order of loading. The four AutoIncrement scripts checked, of six key-generating scripts in the repository, omit the key column for 10 of the 11 tables and let the database number rows as they load. All 6,892 of those rows, every row outside PlaylistTrack, land on the right key, because the reference ids run from 1 with no gaps in file order. Drop one row upstream and every later key, and every foreign key pointing at those rows, shifts without an error.
Money stored as floating point: the task that failed in its own tool
The prebuilt SQLite databases hold the reference values, but not as the same kind of number. All 6,155 price and total cells (3,503 track prices, 2,240 invoice-line prices and 412 invoice totals) are stored as REAL, which SQLite's datatype documentation defines as an 8-byte IEEE floating-point number; a column declared NUMERIC(10,2) takes numeric affinity and keeps 0.99 as a float because it is not a whole number.
Read into exact decimals, every invoice still reconciles: 412 of 412. Written the way an analyst would write it inside SQLite, comparing each invoice total with the sum of unit price times quantity, the same check matches 355 of 412 invoices. The other 57 fail on binary rounding, not on data, and rounding both sides to cents restores all 412.
The maintainers met the same problem. The commit of 4 October 2025 that rebuilt the SQLite files also changed the repository's invoice-total test to wrap the sum in ROUND with two decimals. PostgreSQL's documentation recommends its numeric type for monetary amounts where exactness is required, and the PostgreSQL rendering declares NUMERIC(10,2). The lesson for acceptance: replay the business task in the buyer's own tool and number type, because an exact-decimal replay in the supplier's environment proves the data, not its consumption.
Can a loadable file with a valid checksum be the wrong version?
Yes, and Chinook's own history shows both halves of the problem. At tag v1.4.5, dated 11 February 2024, the two prebuilt SQLite databases loaded cleanly, carried all 15,607 rows, resolved every key and relationship and matched every price, name and identifier. Yet all 412 invoice dates sat exactly 12 years early, running from 2009-01-01 to 2013-12-22 instead of 2021-01-01 to 2025-12-22, and track 2 had lost its composer. Those files were last changed on 19 February 2022, before the JSON source was rewritten on 24 January 2024, and were rebuilt on 4 October 2025.
A checksum would have confirmed those files arrived intact; it cannot say they describe the release beside them. The database files carry no version label, while every script's header reads Version 1.4.5. The opposite case sits in the same tag: four scripts, for SQLite, MySQL, SQL Server Compact and Oracle, changed every line between v1.4.5 and the current commit because their line endings moved from CRLF to LF, and the Oracle script also rewrote its user-setup statements, yet their parsed content did not change.
A content digest separates the two cases. Hashing the parsed rows, sorted by key, with blanks and nulls folded under one declared rule, gives one value, 67c395156b504bc1, for the reference and all nine current renderings; the same value for the four re-encoded scripts at the tag; and a different value, 6002aa853934c33f, for the tag's SQLite files. Byte checksums prove transfer and content digests prove sameness. Neither proves meaning, which is why checks 4 to 7 exist.
The versioned delivery manifest for a multi-format delivery
Ship one manifest with the reference copy and every rendering, and make each field testable. The values in brackets are what this test would record for Chinook.
At a glance
The versioned delivery manifest for a multi-format delivery
- Release and reference: one release identifier, the reference file with its content digest (ChinookData.json, 67c395156b504bc1) and the source commit (7f67772).
- Renderings: for each file, its target system, generator, generation date, byte checksum, line-ending convention and content digest, so that a re-encoded file and a stale one can be told apart.
- Name map: every reference table and column beside each rendering's spelling (UnitPrice as unit_price in PostgreSQL).
- Null rule per column: whether an empty string and a null are the same fact, and how each rendering writes them (1,337 blanks written as NULL).
- Number and date types: exact or floating storage for every amount, the comparison rule for amounts, and whether dates carry a time and a time zone (REAL in the SQLite files; all 428 dates at midnight).
- Key policy: explicit or generated keys, with an assertion that ids run without gaps in load order wherever keys are generated (6,892 rows depend on it).
- Relationships: every foreign key the reference implies and each rendering declares (11 of 11).
- Task replay: the business task, the query in each consumer's dialect and the expected result (412 of 412 invoice totals).
Accept, hold or return: the decision rule and checklist
Accept a rendering when checks 1 to 3 pass, its content digest equals the reference digest under the declared rules, and the task replay in the buyer's own tool returns the expected result. Hold it when the data is right but a declaration is missing: an undeclared name map, null rule or number type is a documentation fix, not a reload. Return it when the content digest differs, keys or relationships fail, or the task replay fails for a reason other than a declared rounding rule.
Under that rule, every current Chinook rendering would be accepted once its manifest declares the null rule, the PostgreSQL name map and the rounding rule for the SQLite files, and the v1.4.5 SQLite databases would be returned. Run these steps on each rendering, in order:
Checklist · 8 items
- Read every file with a reader you wrote or trust, never by running the supplier's scripts, and record the reader and its version.
- Count rows per table and compare key sets with the reference copy.
- Resolve every declared relationship and list orphans by key.
- Map names through the manifest and reject any column without a mapping.
- Compare cells under the declared null, number and date rules, and print every difference.
- Compute the content digest and compare it with the manifest; check the byte checksum separately.
- Replay the business task in the consumer's dialect and number type, and record the result.
- Send the supplier the failing keys and the rule each broke, not a summary.
0 of 8 ticked. Tick each item as you go.
Putting the consumption format into a data request
Name the consumption formats before anything is prepared. SourceX's buyers page says that format, quality checks and delivery method are agreed for each dataset and that each dataset follows a preparation specification agreed before delivery. Its request form carries an Additional specifications field next to source systems, historical timeframe, licensing and de-identification requirements, which is where the intended formats, the task to replay and the manifest fields above can be written down.
SourceX looks for companies that already hold the records a buyer describes instead of selling from an inventory, and no records move until the supplying company has signed off the scope and the terms. Writing the interoperability test into the request lets everyone agree what passing means before the first file is cut. It makes the delivery checkable; it does not promise that the data will improve a model.
Methods note: commit, parser rules, counting rules and limits
Data: github.com/lerocha/chinook-database, partial clone with full history, files read at commit 7f67772503d71ba90f19283c38e93923addb43fa (committed 2025-10-05T16:24:51-07:00) and, for check 8, files extracted with git show from tag v1.4.5 (commit 4a944a942426e1f3263fe539155fb7ef92b04b4a, 2024-02-11T20:49:15-08:00); 23 commits separate them, merges included. Scripts: xs0949_interop.py, xs0949_tag_sqlite_diff.py and xs0949_git_facts.sh, with their outputs, kept for recount; free-text values are not printed in the outputs. They read files and call git only; no repository code or SQL script was executed. Checked 2026-10-28.
Parsing: files are decoded as UTF-8 with any byte-order mark removed (the XSD has one; no data file does). Identifiers are normalized by removing brackets, backticks and double quotes, dropping a schema prefix such as dbo, removing underscores and lower-casing, so unit_price and UnitPrice map to one column; a name counts as spelled differently when the raw name differs from the reference in any character. CREATE TABLE blocks give column types and widths; foreign keys come from inline FOREIGN KEY clauses or ALTER TABLE statements, and in the SQLite files from PRAGMA foreign_key_list. INSERT statements are tokenized: doubled apostrophes are unescaped, an N prefix is recorded and dropped, || joins literals and chr(n) becomes the character with code n, NULL is null, numbers are exact decimals, and dates are read in four patterns (YYYY-MM-DDTHH:MM:SS, YYYY-MM-DD HH:MM:SS, YYYY/M/D and YYYY-M-D HH:MM:SS, including the first argument of TO_DATE). In the SQLite files, a REAL value becomes the decimal of its shortest round-trip text, so the stored double for 0.99 reads as 0.99.
Counting rules: rows are matched to reference rows on the primary key from the XSD, with PlaylistId plus TrackId for PlaylistTrack; the 66,439 cells compared per rendering are the sum over tables of rows times columns. A cell matches when the normalized values are equal; a reference empty string against NULL is counted under check 6 and nowhere else. Relationships count non-null child values missing from the parent's key set. Width checks count text values longer than the declared width in characters, and values within it in characters but longer in UTF-8 bytes; both counts were 0 in every rendering. The task sums unit price times quantity per invoice in exact decimals; in the SQLite files it is also run as an SQL equality, and with round(..., 2) on both sides. The content digest is SHA-256 over tables in reference order, rows sorted by key, values in reference column order, an empty string and NULL both written as one null token, decimals normalized and dates in ISO 8601; the first 16 hexadecimal characters are shown. For the four AutoIncrement scripts checked (the PostgreSQL SerialPKs and SQL Server Compact AutoIncrementPKs scripts were not), a row's implied key is its 1-based position in insert order, compared with the reference row holding that key. Dates of commits are shown as recorded, with their offsets.
Limits: one small, partly fictitious dataset; no database engine loaded the scripts, so what an engine would store is inferred from the script text and the cited documentation, not observed, and engine settings such as Oracle's character set were not tested. Only committed files were read, not release downloads. The findings describe this repository, not any supplier's delivery.
Frequently asked questions
What is a dataset interoperability acceptance test?
It is a check that a delivered dataset keeps the same records, keys, relationships, values and meaning in every format the buyer will load, and that a business task rebuilt from it gives the same answer in each. It compares each rendering with a reference copy rather than trusting that a file which loads is correct.
Is a checksum enough to accept a dataset delivered in several formats?
No. A checksum proves a file arrived as sent, not that it matches the reference copy or means the same thing. In the Chinook repository, four scripts changed every line with no change in content, while two database files that would verify against their own checksums carried invoice dates 12 years early.
Why would an empty string turn into NULL, and does it matter?
Many conversion tools and some databases write empty text as NULL; Oracle documents that it treats a zero-length character value as null. It matters when blank and unknown are different facts, because counts of missing values and filters on them change with the format. Declare the rule per column in the manifest.
Should prices and totals be delivered as floating-point numbers?
Deliver amounts in an exact decimal type, or declare the comparison rule if a format stores binary floating point. In the SQLite files tested here, an exact SQL comparison rebuilt 355 of 412 invoice totals, and rounding to cents rebuilt all 412.
Does passing this test mean a model trained on the data will improve?
No. The test shows that the delivery is the same dataset, with the same meaning, in each consumption format. Whether the data helps a model is a separate question that needs its own evaluation on the buyer's task.
Sources
- Chinook sample database: README, MIT license and data files (ChinookData.json, ChinookDataSet.xsd, seven SQL scripts, two SQLite databases, four of the six key-generating scripts) read at commit 7f67772 for every count on this page. Source
- Files at tag v1.4.5 (2024-02-11), read with git show: the prebuilt SQLite databases with invoice dates 12 years earlier than the JSON, and four scripts with CRLF line endings. Source
- The 4 October 2025 commit that rebuilt the SQLite databases and wrapped the invoice-total test's sum in ROUND with two decimals. Source
- SQLite stores REAL values as 8-byte IEEE floating-point numbers, and a column with NUMERIC affinity stores a well-formed real literal as REAL. Source
- Oracle Database currently treats a character value with a length of zero as null, and Oracle advises against treating empty strings the same as nulls. Source
- PostgreSQL recommends its numeric type for monetary amounts and other quantities where exactness is required. Source
- SourceX says format, quality checks and delivery method are agreed for each dataset, and each dataset follows a dataset-specific preparation specification agreed before delivery. Source
- SourceX's request form, with fields for source systems, historical timeframe, licensing, de-identification and additional specifications; datasets are sourced on request, not held in stock. Source
- The supplying company approves the scope and terms and signs before any data is delivered. Source
Tell us what data you need
Share scope, volume, format, timing and licensing needs. Datasets are sourced on request.