Query Speed
Self-test
Check your understanding
Self-test6 questions
—/6
Why did the first schema benchmark report that a lookup on a non-key column read only 1.7 M of 20 M rows?
A table sorted by (user_id, ts) answers per-user queries from 8,192 rows. Why does the same table read all 20 M rows for a per-country query?
Why did the bloom filter on url skip almost nothing while the one on user_id skipped most of the table?
The materialized view made a counts query 5x faster but a p95 query barely faster. What was in the view's table?
Why did system.parts show no extra disk for a projection, and where is its size?
- Design question
A product has a per-user activity page and a per-country dashboard over the same events. Design the table, the projections or views, and say what each costs.