code: func (e *TopNExec) Next(ctx context.Context, req *chunk.RecordBatch) error {
  	if span := opentracing.SpanFromContext(ctx); span != nil && span.Tracer() != nil {
  		span1 := span.Tracer().StartSpan("topN.Next", opentracing.ChildOf(span.Context()))
  		defer span1.Finish()
  	}
  	if e.runtimeStats != nil {
  		start := time.Now()
  		defer func() { e.runtimeStats.Record(time.Since(start), req.NumRows()) }()
  	}
  	req.Reset()
  	if !e.fetched {
  		e.totalLimit = e.limit.Offset + e.limit.Count
  		e.Idx = int(e.limit.Offset)
  		err := e.loadChunksUntilTotalLimit(ctx)
  		if err != nil {
  			return err
  		}
  		err = e.executeTopN(ctx)
  		if err != nil {
  			return err
  		}
  		e.fetched = true
  	}
  	if e.Idx >= len(e.rowPtrs) {
  		return nil
  	}
  	for !req.IsFull() && e.Idx < len(e.rowPtrs) {
  		row := e.rowChunks.GetRow(e.rowPtrs[e.Idx])
  		req.AppendRow(row)
  		e.Idx++
  	}
  	return nil
  }
docs: // Next implements the Executor Next interface.