---
title: "Join me if you can: ClickHouse vs. Databricks vs. Snowflake - Part 2"
description: "Replacing fact-to-dimension joins with in-memory dictionaries in ClickHouse Cloud sped up a 17-query join benchmark over 1.4 billion rows by 1.9–3.5× in total runtime, up to 6.6× on individual queries, and cut cost by up to 60%."
url: "https://swe.quest/articles/join-me-if-you-can-clickhouse-vs-databricks-vs-snowflake-part-2-66aede87450dc5eb"
canonical: "https://clickhouse.com/blog/join-me-if-you-can-clickhouse-vs-databricks-snowflake-part-2"
source: "ClickHouse"
published: "2025-06-25"
difficulty: "medium"
kind: "Research"
reading_minutes: 8
tags: ["analytics","performance","query-engines","sql"]
---

# Join me if you can: ClickHouse vs. Databricks vs. Snowflake - Part 2

A post on [ClickHouse](https://swe.quest/sources/clickhouse.md), published 2025-06-25, 8 min read, Research. Original: [https://clickhouse.com/blog/join-me-if-you-can-clickhouse-vs-databricks-snowflake-part-2](https://clickhouse.com/blog/join-me-if-you-can-clickhouse-vs-databricks-snowflake-part-2)

## Summary

Replacing fact-to-dimension joins with in-memory dictionaries in ClickHouse Cloud sped up a 17-query join benchmark over 1.4 billion rows by 1.9–3.5× in total runtime, up to 6.6× on individual queries, and cut cost by up to 60%. The Locations table becomes a complex\_key\_hashed dictionary for String-key lookups. The Products table becomes a range\_hashed dictionary that resolves time-versioned rows with a hash map plus binary search over date ranges, provided the source has no overlapping ranges per key. Queries change only by swapping JOINs for dictGet calls, and the gains grew as the cluster scaled from 2 to 8 nodes.

Written by swe.quest, not by the author.

**Difficulty:** Medium: assumes a working developer; shows how it is built or done

## Topics

- [Analytics & OLAP](https://swe.quest/tags/analytics.md) (Data & databases)
- [Performance engineering](https://swe.quest/tags/performance.md) (Reliability & operations)
- [Query engines](https://swe.quest/tags/query-engines.md) (Data & databases)
- [SQL](https://swe.quest/tags/sql.md) (Languages)

## Prerequisites

- SQL joins ([easy posts on SQL](https://swe.quest/tags/sql.md?difficulty=easy))
- star schema data modeling
- columnar OLAP databases ([easy posts on Analytics & OLAP](https://swe.quest/tags/analytics.md?difficulty=easy))

## Keywords

ClickHouse, ClickHouse Cloud, ClickHouse dictionaries, dictGet, Apache Iceberg, Snowflake, Databricks, Parallel Replicas

## Related posts

- [Using Dictionaries to Accelerate Queries](https://swe.quest/articles/using-dictionaries-to-accelerate-queries-fcf5f4fb14453a0d.md): ClickHouse · 2022-12-07 · Medium · 17 min read · Query engines, Analytics & OLAP, SQL, Performance engineering
  ClickHouse dictionaries, in-memory key-value structures, can replace JOINs against small lookup tables.
- [Join me if you can: ClickHouse vs. Databricks vs. Snowflake - Part 1](https://swe.quest/articles/join-me-if-you-can-clickhouse-vs-databricks-vs-snowflake-part-1-abef280c3cc66c97.md): ClickHouse · 2025-06-24 · Easy · 7 min read · Analytics & OLAP, Performance engineering, Query engines, Cost optimization
  ClickHouse Cloud ran a third-party, join-heavy coffee-shop star-schema benchmark (17 queries, originally built to compare Databricks and Snowflake) with no query rewrites or tuning, and came out faster and cheaper at every scale from 721 million to 7.2 billion rows.
- [ClickHouse Joins Under the Hood - Direct Join](https://swe.quest/articles/clickhouse-joins-under-the-hood-direct-join-4c5bfc57b28f012b.md): ClickHouse · 2023-06-07 · Medium · 15 min read · Query engines, Analytics & OLAP, Performance engineering, SQL
  ClickHouse's direct join is its fastest join algorithm. It applies when the right-hand table sits on storage that supports low-latency key-value lookups: the Join engine, EmbeddedRocksDB or a Dictionary.
- [ClickHouse Cloud: Fast, Updatable Lookups with the Join Table Engine](https://swe.quest/articles/clickhouse-cloud-fast-updatable-lookups-with-the-join-table-engine-b50f6e80ec781fcd.md): ClickHouse · 2026-05-12 · Medium · 6 min read · Analytics & OLAP, Databases, SQL, Cloud platforms
  ClickHouse's Join table engine keeps a precomputed in-memory hash map for a fixed join strictness, type and key.
- [Trade secrets: How Coinhall uses ClickHouse to power its blockchain data platform](https://swe.quest/articles/trade-secrets-how-coinhall-uses-clickhouse-to-power-its-blockchain-data-platform-a19f7fb99396fe78.md): ClickHouse · 2024-08-14 · Easy · 5 min read · Analytics & OLAP, Databases, Performance engineering, Cost optimization
  Coinhall, an omnichain trading terminal aggregating swap data from 23 blockchains, moved from BigQuery (about 2-second queries, thousands of dollars per month) to QuestDB and then to self-hosted ClickHouse.

Browse: [Latest posts](https://swe.quest/index.md) · [Topics](https://swe.quest/tags.md) · [Sources](https://swe.quest/sources.md) · [Topic map](https://swe.quest/map.md) · [Site guide (llms.txt)](https://swe.quest/llms.txt)
