query users not working right