Collection 06
Data
Interpret bytes, fields, and records without guessing.
Data entries begin with the smallest sample that exposes the format. They show where a record starts and ends, which bytes are ambiguous, and what a parser is entitled to ignore.
5 entries
Download the collection index (JSON)Index
On this shelf
| Name | Format | Interpretation question |
|---|---|---|
| Quotes and Line Breaks in CSV Reference | CSV | When is a line break part of a field instead of a record boundary? |
| Recognizing a UTF-8 BOM Reference | Encoding | How do I detect a BOM, and should I remove it? |
| Record Boundaries in JSON Lines Reference | JSON | What separates two records, and why can a pretty-printed object not be one line? |
| Testing for NULL in SQL Question & Answer | SQL | Why does column = NULL never match, and what should I write instead? |
| Can You Average Two p95 Latencies? Question & Answer | Statistics | What information do two p95 values lose about the combined request stream? |
Reading path
A way in
Start with the BOM entry when an otherwise valid text file begins with invisible bytes. The CSV and JSON Lines entries show two different answers to where a record ends.
- 01 Recognizing a UTF-8 BOMA UTF-8 BOM is the byte sequence EF BB BF at the start of a text stream; inspect the first three bytes before decoding, and strip it unless the consuming format explicitly expects it.
- 02 Quotes and Line Breaks in CSVA line break belongs to a CSV field only when it appears inside a double-quoted field; outside quotes it ends the record, so wrap the field in double quotes and double any embedded quotes.
- 03 Record Boundaries in JSON LinesIn JSON Lines each record is one complete JSON value on a single line, with LF as the record separator; a pretty-printed object spans multiple lines and is therefore not valid JSON Lines.
All entries
Full catalog
- Can You Average Two p95 Latencies? To find the p95 across two servers, pool their requests or merge compatible histograms. Even a request-weighted average of the two p95 values can be far from the pooled result.
- Quotes and Line Breaks in CSV A line break belongs to a CSV field only when it appears inside a double-quoted field; outside quotes it ends the record, so wrap the field in double quotes and double any embedded quotes.
- Recognizing a UTF-8 BOM A UTF-8 BOM is the byte sequence EF BB BF at the start of a text stream; inspect the first three bytes before decoding, and strip it unless the consuming format explicitly expects it.
- Record Boundaries in JSON Lines In JSON Lines each record is one complete JSON value on a single line, with LF as the record separator; a pretty-printed object spans multiple lines and is therefore not valid JSON Lines.
- Testing for NULL in SQL column = NULL never matches because NULL means unknown rather than a value, and comparisons with it evaluate to UNKNOWN; write column IS NULL or column IS NOT NULL instead.