@@ -6,82 +6,38 @@ type RuleId int
66
77const (
88 // once before
9- applyDefaultSelectLimitId RuleId = iota // applyDefaultSelectLimit
10- validateOffsetAndLimitId // validateOffsetAndLimit
11- validateStarExpressionsId // validateStarExpressions
12- validateCreateTableId // validateCreateTable
13- validateAlterTableId // validateAlterTable
14- validateExprSemId // validateExprSem
15- resolveVariablesId // resolveVariables
16- resolveNamedWindowsId // resolveNamedWindows
17- resolveSetVariablesId // resolveSetVariables
18- resolveViewsId // resolveViews
19- liftCtesId // liftCtes
20- resolveCtesId // resolveCtes
21- liftRecursiveCtesId // liftRecursiveCtes
22- resolveDatabasesId // resolveDatabases
23- resolveTablesId // resolveTables
24- loadStoredProceduresId // loadStoredProcedures
25- validateDropTablesId // validateDropTables
26- pruneDropTablesId // pruneDropTables
27- setTargetSchemasId // setTargetSchemas
28- resolveCreateLikeId // resolveCreateLike
29- parseColumnDefaultsId // parseColumnDefaults
30- resolveDropConstraintId // resolveDropConstraint
31- validateDropConstraintId // validateDropConstraint
32- loadCheckConstraintsId // loadCheckConstraints
33- assignCatalogId // assignCatalog
34- resolveAnalyzeTablesId // resolveAnalyzeTables
35- resolveCreateSelectId // resolveCreateSelect
36- resolveSubqueriesId // resolveSubqueries
37- setViewTargetSchemaId // setViewTargetSchema
38- resolveUnionsId // resolveUnions
39- resolveDescribeQueryId // resolveDescribeQuery
40- checkUniqueTableNamesId // checkUniqueTableNames
41- resolveTableFunctionsId // resolveTableFunctions
42- resolveDeclarationsId // resolveDeclarations
43- resolveColumnDefaultsId // resolveColumnDefaults
44- ValidateColumnDefaultsId // validateColumnDefaults
45- validateCreateTriggerId // validateCreateTrigger
46- validateCreateProcedureId // validateCreateProcedure
47- resolveCreateProcedureId // resolveCreateProcedure
48- loadInfoSchemaId // loadInfoSchema
49- validateReadOnlyDatabaseId // validateReadOnlyDatabase
50- validateReadOnlyTransactionId // validateReadOnlyTransaction
51- validateDatabaseSetId // validateDatabaseSet
52- validatePrivilegesId // validatePrivileges
53- reresolveTablesId // reresolveTables
54- setInsertColumnsId // setInsertColumns
55- validateJoinComplexityId // validateJoinComplexity
56- applyBinlogReplicaControllerId // applyBinlogReplicaController
57- applyEventSchedulerId // applyEventScheduler
9+ applyDefaultSelectLimitId RuleId = iota // applyDefaultSelectLimit
10+ validateOffsetAndLimitId // validateOffsetAndLimit
11+ validateStarExpressionsId // validateStarExpressions
12+ validateCreateTableId // validateCreateTable
13+ validateAlterTableId // validateAlterTable
14+ validateExprSemId // validateExprSem
15+ loadStoredProceduresId // loadStoredProcedures
16+ validateDropTablesId // validateDropTables
17+ resolveDropConstraintId // resolveDropConstraint
18+ validateDropConstraintId // validateDropConstraint
19+ resolveCreateSelectId // resolveCreateSelect
20+ resolveSubqueriesId // resolveSubqueries
21+ resolveUnionsId // resolveUnions
22+ resolveDescribeQueryId // resolveDescribeQuery
23+ ValidateColumnDefaultsId // validateColumnDefaults
24+ validateCreateTriggerId // validateCreateTrigger
25+ validateCreateProcedureId // validateCreateProcedure
26+ validateReadOnlyDatabaseId // validateReadOnlyDatabase
27+ validateReadOnlyTransactionId // validateReadOnlyTransaction
28+ validateDatabaseSetId // validateDatabaseSet
29+ validatePrivilegesId // validatePrivileges
30+ applyEventSchedulerId // applyEventScheduler
5831
5932 // default
60- resolveUsingJoinsId // resolveUsingJoins
61- resolveOrderbyLiteralsId // resolveOrderbyLiterals
62- resolveFunctionsId // resolveFunctions
6333 flattenTableAliasesId // flattenTableAliases
64- pushdownSortId // pushdownSort
65- pushdownGroupbyAliasesId // pushdownGroupbyAliases
6634 pushdownSubqueryAliasFiltersId // pushdownSubqueryAliasFilters
67- qualifyColumnsId // qualifyColumns
68- resolveColumnsId // resolveColumns
69- validateCheckConstraintId // validateCheckConstraint
70- resolveBarewordSetVariablesId // resolveBarewordSetVariables
35+ validateCheckConstraintId // validateCheckConstraints
7136 replaceCountStarId // replaceCountStar
72- expandStarsId // expandStars
73- transposeRightJoinsId // transposeRightJoins
74- resolveHavingId // resolveHaving
75- mergeUnionSchemasId // mergeUnionSchemas
76- flattenAggregationExprsId // flattenAggregationExprs
77- reorderProjectionId // reorderProjection
78- resolveSubqueryExprsId // resolveSubqueryExprs
7937 replaceCrossJoinsId // replaceCrossJoins
80- moveJoinCondsToFilterId // moveJoinCondsToFilter
81- moveFiltersToJoinCondId // moveFiltersToJoinCond
38+ moveJoinCondsToFilterId // moveJoinConditionsToFilter
8239 simplifyFiltersId // simplifyFilters
8340 pushNotFiltersId // pushNotFilters
84- optimizeDistinctId // optimizeDistinct
8541
8642 // after default
8743 hoistOutOfScopeFiltersId // hoistOutOfScopeFilters
@@ -90,38 +46,30 @@ const (
9046 finalizeSubqueriesId // finalizeSubqueries
9147 finalizeUnionsId // finalizeUnions
9248 loadTriggersId // loadTriggers
93- loadEventsId // loadEvents
9449 processTruncateId // processTruncate
9550 resolveAlterColumnId // resolveAlterColumn
96- resolveGeneratorsId // resolveGenerators
97- removeUnnecessaryConvertsId // removeUnnecessaryConverts
9851 stripTableNameInDefaultsId // stripTableNamesFromColumnDefaults
99- foldEmptyJoinsId // foldEmptyJoins
10052 optimizeJoinsId // optimizeJoins
101- generateIndexScansId // generateIndexScans
102- matchAgainstId // matchAgainst
10353 pushFiltersId // pushFilters
10454 applyIndexesFromOuterScopeId // applyIndexesFromOuterScope
10555 pruneTablesId // pruneTables
106- fixupAuxiliaryExprsId // fixupAuxiliaryExprs
10756 assignExecIndexesId // assignExecIndexes
10857 inlineSubqueryAliasRefsId // inlineSubqueryAliasRefs
10958 eraseProjectionId // eraseProjection
110- flattenDistinctId //flattenDistinct
59+ flattenDistinctId // flattenDistinct
11160 replaceAggId // replaceAgg
11261 replaceIdxSortId // replaceIdxSort
113- insertTopNId // insertTopN
62+ insertTopNId // insertTopNNodes
11463 replaceIdxOrderByDistanceId // replaceIdxOrderByDistance
11564 applyHashInId // applyHashIn
11665 resolveInsertRowsId // resolveInsertRows
117- resolvePreparedInsertId // resolvePreparedInsert
11866 applyTriggersId // applyTriggers
11967 applyProceduresId // applyProcedures
12068 assignRoutinesId // assignRoutines
12169 modifyUpdateExprsForJoinId // modifyUpdateExprsForJoin
122- applyRowUpdateAccumulatorsId // applyRowUpdateAccumulators
123- wrapWithRollbackId // rollback triggers
124- applyFKsId // applyFKs
70+ applyUpdateAccumulatorsId // applyUpdateAccumulators
71+ wrapWithRollbackId // wrapWithRollback
72+ applyForeignKeysId // applyForeignKeys
12573
12674 // validate
12775 validateResolvedId // validateResolved
@@ -130,19 +78,16 @@ const (
13078 validateSchemaSourceId // validateSchemaSource
13179 validateIndexCreationId // validateIndexCreation
13280 ValidateOperandsId // validateOperands
133- validateCaseResultTypesId // validateCaseResultTypes
13481 validateIntervalUsageId // validateIntervalUsage
135- validateExplodeUsageId // validateExplodeUsage
13682 validateSubqueryColumnsId // validateSubqueryColumns
13783 validateUnionSchemasMatchId // validateUnionSchemasMatch
13884 validateAggregationsId // validateAggregations
13985 validateDeleteFromId // validateDeleteFrom
14086
14187 // after all
142- cacheSubqueryResultsId // cacheSubqueryResults
14388 cacheSubqueryAliasesInJoinsId // cacheSubqueryAliasesInJoins
144- backtickDefaulColumnValueNamesId // backtickDefaulColumnValueNames
145- AutocommitId // addAutocommitNode
89+ backtickDefaulColumnValueNamesId // backtickDefaultColumnValueNames
90+ AutocommitId // addAutocommit
14691 TrackProcessId // trackProcess
14792 parallelizeId // parallelize
14893 clearWarningsId // clearWarnings
0 commit comments