code: public int getTotalNumberOfPages() throws QueryException {
  		prepareResultData(false);
  		if (isEmpty()) {
  			return 1;
  		}
  		int total = totalNumberOfEntries / this.pageSize;
  		if (totalNumberOfEntries % this.pageSize > 0) {
  			total += 1;
  		}
  		return total;
  	}
docs: Returns a total number of query pages.
  
  @return total number of pages
  @throws com.gemstone.gemfire.cache.query.QueryException
  during query execution