Corrected getQueryText()