changed the result output of the query script