1. A method for performing a range-sum query on a database of a database system, comprising: processing at least one query using a wavelet transformation in a computing system of the database system to produce a transformed query, wherein the transformed query comprises k wavelet coefficients; and the computing system performing a range-sum query on the database of the database system using the transformed query to produce a result.