queries should return pointers to results