Computing Data Distribution from Query Selectivities
Abstract
We are given a set , where each is a \emph{range} in , such as rectangle or ball, and denotes its \emph{selectivity}. The goal is to compute a small-size \emph{discrete data distribution} , where and for each , and , such that is the most \emph{consistent} with , i.e., is minimized. In a database setting, corresponds to a workload of range queries over some table, together with their observed selectivities (i.e., fraction of tuples returned), and can be used as compact model for approximating the data distribution within the table without accessing the underlying contents. In this paper, we obtain both upper and lower bounds for this problem. In particular, we show that the problem of finding the best data distribution from selectivity queries is -complete. On the positive side, we describe a Monte Carlo algorithm that constructs, in time , a discrete distribution of size , such that (for ) where the minimum is taken over all discrete distributions. We also establish conditional lower bounds, which strongly indicate the infeasibility of relative approximations as well as removal of the exponential dependency on the dimension for additive approximations. This suggests that significant improvements to our algorithm are unlikely.
Keywords
Cite
@article{arxiv.2401.06047,
title = {Computing Data Distribution from Query Selectivities},
author = {Pankaj K. Agarwal and Rahul Raychaudhury and Stavros Sintos and Jun Yang},
journal= {arXiv preprint arXiv:2401.06047},
year = {2024}
}