Total added to grid via query rewriting in gridmaker