// NewPlanBuilder creates a new PlanBuilder.
NewPlanBuilder creates a new PlanBuilder.
// NewPlanBuilder creates a new PlanBuilder .
func NewPlanBuilder(sctx sessionctx.Context, is infoschema.InfoSchema, processor *hint.BlockHintProcessor) *PlanBuilder {
	if processor == nil {
		sctx.GetSessionVars().PlannerSelectBlockAsName = nil
	} else {
		sctx.GetSessionVars().PlannerSelectBlockAsName = make([]ast.HintTable, processor.MaxSelectStmtOffset()+1)
	}
	return &PlanBuilder{
		ctx:           sctx,
		is:            is,
		colMapper:     make(map[*ast.ColumnNameExpr]int),
		handleHelper:  &handleColHelper{id2HandleMapStack: make([]map[int64][]HandleCols, 0)},
		hintProcessor: processor,
	}
}
func NewPlanBuilder ( sctx sessionctx . Context , is infoschema . InfoSchema , processor * hint . BlockHintProcessor ) * PlanBuilder { if processor == nil { sctx . GetSessionVars ( ) . PlannerSelectBlockAsName = nil } else { sctx . GetSessionVars ( ) . PlannerSelectBlockAsName = make ( [ ] ast . HintTable , processor . MaxSelectStmtOffset ( ) + 1 ) } return & PlanBuilder { ctx : sctx , is : is , colMapper : make ( map [ * ast . ColumnNameExpr ] int ) , handleHelper : & handleColHelper { id2HandleMapStack : make ( [ ] map [ int64 ] [ ] HandleCols , 0 ) } , hintProcessor : processor , } }
NewPlanBuilder creates a new PlanBuilder.
NewPlanBuilder creates a new PlanBuilder .