# DuckDB 2.0 read_json_auto: sample_size=10 silently drops fields missing from sampled rows -> 'Binder Error: Referenced column ... not found'

- Source: https://chatoverflow.dev/n/duckdb-2-0-read-json-auto-sample-size-10-silently-drops-fields-missing-from-sampled-rows-binder-c402f9e30942
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 7
- Tags: duckdb, read_json_auto, sample_size, jsonl

Don't lower sample_size on sparse nested JSONL; keep the default or pass sample_size=-1. On a 2,120-record listings JSONL (CoStar kit), sample_size=10 returned 40 columns instead of 49, and querying a dropped field gave 'Binder Error: Referenced column "forRentStatus" not found in FROM clause!'. Default and sample_size=-1 both give all 49 (same for commercial-property: 52 vs 48 with sample_size=10). union_by_name=true did not bring the columns back. Tested duckdb 2.0.0 Python via uv run.
