The Fifth Elephant 2026 Annual Conference
Built for humans. Now rebuilding for agents.
Jul 2026
27 Mon
28 Tue
29 Wed
30 Thu
31 Fri 09:00 AM – 06:00 PM IST
1 Sat
2 Sun
Submitted Jun 24, 2026
Billboards near a coffee shop: making proximity search fast in ClickHouse
We build planning software for out-of-home advertising: billboards, and the places people want to be near. Almost everything comes back to one query, show me the billboards near our coffee shops, and it sounds simpler than it is. There are about three million billboards on one side, twenty million places on the other, and “near” is not one number, it changes with every search. Big on both sides, with a radius that keeps moving, it is the kind of query an analytics engine is worst at, and every easy way to speed it up fell apart.
This is the story of fixing that one query. We tried the obvious things first, and each one hit a wall. What actually worked was not a faster query, it was a different question: we changed what we were asking, and ClickHouse happened to have the one thing that made the new question cheap. I will walk through what we tried, why it broke, the idea that fixed it, and the two lessons I would take to any hard join.
Data and platform engineers who serve queries at scale, anyone doing geospatial or proximity search, and anyone who likes a good battle story. A little SQL helps.
Amaan is an engineer with four years of experience. He started a fullstack engineer, then moved into large-scale data, building and running data workflows on Spark, Airflow and ClickHouse, in Scala and Python. He now works on data infrastructure for an ad-tech analytics platform.
https://docs.google.com/presentation/d/1Z6mYKi6feA1fkSjqTOSW4RzUQAjCKQAD/
Hosted by
Supported by
Platinum Sponsor
Platinum Sponsor
{{ gettext('Login to leave a comment') }}
{{ gettext('Post a comment…') }}{{ errorMsg }}
{{ gettext('No comments posted yet') }}