add query_statistic method to Rewrite module to avoid repeat audit