fixed query issue in setting