Exploring Global Internet Speeds using Apache Iceberg and ClickHouse
ClickHouse's iceberg table function can query the Ookla global internet-speed dataset (128M rows) directly from S3. The schema comes from Iceberg metadata, and the walkthrough includes aggregations such as download-speed quantiles. It notes current gaps: no v2 row-level deletes or schema evolution, no partition pruning, S3-only support, and no use of sort order for file skipping. The data is then loaded into a MergeTree table, WKT tiles are parsed into Ring types, and polygon centroids are computed with shoelace-formula SQL UDFs built on arrayFold. The polygons are rendered as SVG maps using only SQL, with h3 indexes, polygon dictionaries, Mercator projection and color interpolation.
Related posts
- Climbing the Iceberg with ClickHouse
ClickHouse mediumAdept
ClickHouse fits into data lake and lakehouse architectures in three common ways: incrementally loading object-storage or Iceberg data via s3cluster/S3Queue (or double-writing from Kafka), running ad-hoc and federated queries against Iceberg, Delta and Hudi tables plus PostgreSQL, MySQL and MongoDB, and frequently querying shared lakehouse datasets. Version 24.12 adds an Iceberg REST catalog database engine, tested with Snowflake's Polaris, so tables can be discovered and queried without explicit paths. Version 24.11 adds icebergS3Cluster for distributed reads, cutting a 96-billion-row scan from about 2,595s to 907s on three nodes. Planned work covers Iceberg partition pruning, schema evolution and time travel, Delta support via the Rust Delta Kernel, and Glue and Unity catalogs.
- Visualizing Foursquare places with ClickHouse
ClickHouse mediumAdept
The Foursquare open places dataset (about 100 million records) loads straight from S3 Parquet into ClickHouse in 42 seconds and 11 GB. The table stores Web Mercator coordinates as materialized UInt32 columns, is ordered by a Morton (Z-order) space-filling curve, and has minmax indices so map tiles can be queried fast. The existing adsb.exposed air-traffic visualizer was reused with a 48-line change to render pixel-level tiles in the browser. Compared with Foursquare Studio's H3 hexagons, Kepler.gl and DuckDB-based maps, it gives higher resolution and smoother interactivity, but does not correct point density for latitude.
- ClickHouse is data lake ready
ClickHouse mediumAdept
ClickHouse now queries Apache Iceberg and Delta Lake tables in place on S3, GCS and Azure, either directly or through catalogs such as AWS Glue, Unity, Polaris, BigLake, OneLake and Iceberg REST. Teams can load lake data into the native MergeTree engine when they need sub-second, high-concurrency queries, and can write results back to open formats. The groundwork took two years of releases: a native Parquet reader with page-level parallelism that reads about 1.8x faster on ClickBench, integration of the Delta Rust Kernel, Iceberg time travel and DML, and parallel replicas. Worked examples against a 1.29-billion-row NYC taxi Iceberg table show in-place scans taking 50 to 130 seconds before ingestion into MergeTree for faster querying.
- Exploring massive, real-world data sets: 100+ Years of Weather Records in ClickHouse
ClickHouse mediumAdept
A billion-row NOAA GHCN climate dataset (1900–2022) is downloaded, filtered on quality flags and pivoted from one measurement per row to one row per station and day using clickhouse-local, then enriched with station coordinates parsed via the Regexp format. The result is loaded into a MergeTree table ordered by station_id and date. A single INFILE insert of about 1.08 billion rows took roughly 196 seconds; splitting the file into 16 parts and inserting in parallel cut that to 135 seconds, which matched the client's disk read limit. Simple queries then confirm historical records such as Furnace Creek's 56.7°C, scanning about 1 billion rows in about 0.1s.
- IP-based Geolocation in ClickHouse
ClickHouse mediumAdept
ClickHouse's ip_trie dictionary layout enables low-latency IP-to-location lookups once IP ranges are expressed as CIDR blocks. The walkthrough loads the DB-IP city dataset via the URL table engine and converts start/end ranges to CIDR using bitXor, log2/ceil, bitNot and bitAnd. It then builds an in-memory ip_trie dictionary queried with dictGet against SEC EDGAR access logs. For mapping, geohashEncode at low precision with log10-normalized counts rolls 20M+ rows into about 6,300 cells for a Grafana Geo Map panel.