1. A method comprising: by one or more computing devices, receiving a query for data from one or more sets of data that are within a range, wherein the one or more sets of data are represented by a first binary decision diagram (BDD); constructing a second BDD representing the range; and constructing a third BDD representing the data within the range by performing an AND operation between the first BDD and the second BDD.