Query modification