query audit fix