setting total number of result rows