*: add materialized view DDL syntax#66022
Conversation
|
Tests:
|
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## feature/release-8.5-materialized-view #66022 +/- ##
==========================================================================
Coverage ? 57.0830%
==========================================================================
Files ? 1784
Lines ? 638126
Branches ? 0
==========================================================================
Hits ? 364262
Misses ? 249394
Partials ? 24470
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
- Drop unused MV keywords (INCLUDING/NEW/DEMAND) - Align CREATE MV refresh on-clause to [START WITH] NEXT - Add COMPLETE refresh type - Support TIFLASH REPLICA for MV LOG + ALTER actions - Extend ALTER MV LOG purge syntax + tests
|
/retest |
1 similar comment
|
/retest |
| p.checkCreateViewGrammar(node) | ||
| p.checkCreateViewWithSelectGrammar(node) |
There was a problem hiding this comment.
Shall we also add these check for mv?
| case *ast.CreateResourceGroupStmt, *ast.DropResourceGroupStmt, *ast.AlterResourceGroupStmt: | ||
| err := plannererrors.ErrSpecificAccessDenied.GenWithStackByArgs("SUPER or RESOURCE_GROUP_ADMIN") | ||
| b.visitInfo = appendDynamicVisitInfo(b.visitInfo, []string{"RESOURCE_GROUP_ADMIN"}, false, err) | ||
| case *ast.CreateMaterializedViewStmt: |
There was a problem hiding this comment.
These case branch has some common logic, better to extract some functions to call.
pkg/parser/parser.y
Outdated
| } | ||
|
|
||
| CreateMaterializedViewLogStmt: | ||
| "CREATE" "MATERIALIZED" "VIEW" "LOG" "ON" TableName '(' ColumnList ')' MLogOptionClauseOpt MLogPurgeClauseOpt |
There was a problem hiding this comment.
Currently, MLogOptionClauseOpt must be placed beforeMLogPurgeClauseOpt, reverse order is not supported. If we want a flexible order, this needs to be adjusted.
There was a problem hiding this comment.
We don't support the reverse order
…ed-view' into mv/scheme2-split-pr1-parser
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: fzzf678, windtalker The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
[LGTM Timeline notifier]Timeline:
|
|
/retest |
2 similar comments
|
/retest |
|
/retest |
96a16b2
into
pingcap:feature/release-8.5-materialized-view
What problem does this PR solve?
Issue Number: ref #65936 ref #18023
Problem Summary:
What changed and how does it work?
parser.goregeneration).Check List
Tests
Side effects
Documentation
Release note
Please refer to Release Notes Language Style Guide to write a quality release note.