code: func (e *groupChecker) meetNewGroup(row chunk.Row) (bool, error) {
  	if len(e.GroupByItems) == 0 {
  		return false, nil
  	}
  	e.tmpGroupKey = e.tmpGroupKey[:0]
  	matched, firstGroup := true, false
  	if len(e.curGroupKey) == 0 {
  		matched, firstGroup = false, true
  	}
  	for i, item := range e.GroupByItems {
  		v, err := item.Eval(row)
  		if err != nil {
  			return false, err
  		}
  		if matched {
  			c, err := v.CompareDatum(e.StmtCtx, &e.curGroupKey[i])
  			if err != nil {
  				return false, err
  			}
  			matched = c == 0
  		}
  		e.tmpGroupKey = append(e.tmpGroupKey, v)
  	}
  	if matched {
  		return false, nil
  	}
  	e.curGroupKey = e.curGroupKey[:0]
  	for _, v := range e.tmpGroupKey {
  		e.curGroupKey = append(e.curGroupKey, *((&v).Copy()))
  	}
  	return !firstGroup, nil
  }
docs: // meetNewGroup returns a value that represents if the new group is different from last group.
  // TODO: Since all the group by items are only a column reference, guaranteed by building projection below aggregation, we can directly compare data in a chunk.