db select queries tested