CSV with Mixed Null Representations
A CSV where missing values are written seven different ways — empty string, NULL, NA, N/A, null, None, and a dash — across text and numeric columns. A fixture for testing null-detection and coercion in CSV importers.
id,name,score,joined,notes
1,Ada,91,2025-03-01,ok
2,,NULL,2025-04-11,NA
3,Chen,N/A,,null
4,None,74,2025-06-30,-
5,Priya,,null,
6,NA,88,2025-08-19,n/a
7,Omar,None,2025-09-02,NULL
8,Sofia,67,2025-10-15,-
Specifications
- Rows
- 8
- Null Tokens
- '', NULL, NA, N/A, null, None, -
- Note
- missing values written seven different ways
What is a .csv file?
CSV (Comma-Separated Values) is a plain-text tabular format where rows are lines and fields are separated by commas, with quoting rules for values that contain delimiters, quotes, or newlines. It has no formal type system and depends on encoding and dialect conventions. It is the most portable format for tabular data exchange.
How to use this file
Use an example CSV to test parsers against quoting and embedded-delimiter edge cases, header handling, encoding detection, and import pipelines into databases or spreadsheets.
Code examples
import pandas as pd
df = pd.read_csv("nulls-and-missing.csv")
print(df.head())
print(df.dtypes)Related files
- csvCSV with Mixed Timestamp FormatsA CSV listing timestamps in eleven formats — ISO 8601 with Z and numeric offsets, millisecond precision, naive local, date-only, Unix epoch in seconds and milliseconds, US AM/PM, and RFC 1123. A fixture for testing date parsing and timezone normalisation.

- csvCSV with Mixed-Type ColumnsA CSV whose 'value' column mixes integers, floats, scientific notation, dates, hex, thousands separators, and whitespace, and whose 'flag' column mixes a dozen boolean spellings. A torture test for type inference and schema detection.

- csvWide CSV — 1000 ColumnsA CSV with 1000 columns and a handful of rows — a stress test for parsers, spreadsheet importers, and databases with column limits or per-row buffering assumptions. Deterministic (fixed seed).

- csv10,000-Row CSVA CSV with 10,000 data rows — for testing streaming parsers, memory handling, and import performance.

- csvClean CSVA clean, well-formed CSV with a header and 20 rows — the baseline case for CSV parser testing.

- csvMessy CSV (quoted commas, newlines, ragged rows)A deliberately messy CSV: a quoted field with a comma, a quoted field with an embedded newline, escaped double-quotes, and ragged rows with too few and too many fields — the cases that break naïve parsers.

Generated by generation/data_edgecases.py. Free for any use, no attribution required — license.