update printing of query