Lune

SIGMOD2024Top-tier venue

Reservoir Sampling over Joins

Binyang Dai, Xiao Hu, Ke Yi

Abstract

Sampling over joins is a fundamental task in large-scale data analytics. Instead of computing the full join results, which could be massive, a uniform sample of the join results would suffice for many purposes, such as answering analytical queries or training machine learning models. In this paper, we study the problem of how to maintain a random sample over joins while the tuples are streaming in. Without the join, this problem can be solved by some simple and classical reservoir sampling algorithms. However, the join operator makes the problem significantly harder, as the join size can be polynomially larger than the input. We present a new algorithm for this problem that achieves a near-linear complexity. The key technical components are a generalized reservoir sampling algorithm that supports a predicate, and a dynamic index for sampling over joins. We also conduct extensive experiments on both graph and relational data over various join queries, and the experimental results demonstrate significant performance improvement over the state of the art.

Ask Lune

Know this paper in minutes, not an afternoon.

Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.

4 top-tier papers have cited it since. Know what they found before your reviewers do.

Questions to start from

Lune can draw on

the full paper · the top-tier papers that cite it · related work

Get the answer

Free to start. No credit card required.

Lineage

  • Change Propagation Without Joins cites Maintaining Acyclic Foreign-Key Joins under Updates
  • Random Sampling Over Spatial Range Joins cites Efficient Join Synopsis Maintenance for Data Warehouse
Builds onCited byLeft to right by year; the more cited, the higher.

Cited by top-tier papers4

  1. Random Sampling Over Spatial Range JoinsDaichi AmagataICDE 2025 · 3 citations
  2. Poisson Sampling over Acyclic JoinsLiese Bekkers, Frank Neven, Lorrens Pantelis, Stijn VansummerenSIGMOD 2026 · 1 citation
  3. Exploring Exploratory QueryingMarcelo Arenas, Enrico Franconi, Janik Hammerer, Olaf Hartig et al.VLDB 2025
  4. Secure Multi-Party Sampling over JoinsQiyao Luo, Quanqing Xu, Chuanhui YangVLDB 2026

Builds on4

  1. The LDBC Social Network Benchmark: Business Intelligence WorkloadGábor Szárnyas, Jack Waudby, Benjamin A. Steer, Dávid Szakállas et al.VLDB 2023 · 103 citations
  2. Change Propagation Without JoinsQichen Wang, Xiao Hu, Binyang Dai, Ke YiVLDB 2023 · 23 citations
  3. Efficient Join Synopsis Maintenance for Data WarehouseZhuoyue Zhao, Feifei Li, Yuxi LiuSIGMOD 2020 · 19 citations
  4. Maintaining Acyclic Foreign-Key Joins under UpdatesQichen Wang, Ke YiSIGMOD 2020 · 13 citations

Related papers

  1. GREAT: Generalized Reservoir Sampling based Triangle Counting Estimation over Streaming GraphsSiyue Wu, Dingming Wu, Sinhong Cheuk, Tsz Nam Chan et al.VLDB 2025
  2. Practical Dynamic Extension for Sampling IndexesDouglas B. Rumbaugh, Dong XieSIGMOD 2024 · 3 citations
  3. Enabling Adaptive Sampling for Intra-Window Join: Simultaneously Optimizing Quantity and QualityXilin Tang, Feng Zhang, Shuhao Zhang, Yani Liu et al.SIGMOD 2025 · 1 citation
  4. PGMJoins: Random Join Sampling with Graphical ModelsAli Mohammadi Shanghooshabad, Meghdad Kurmanji, Qingzhi Ma, Michael Shekelyan et al.SIGMOD 2021 · 13 citations
  5. Efficient Streaming Algorithms for Graphlet SamplingYann Bourreau, Marco Bressan, T.-H. Hubert Chan, Qipeng Kuang et al.NeurIPS 2024 · 1 citation
Dusk over the sea between two cliffs drawn in fine vertical lines