Small query changes