sendQuery beautified