From faaef33f7653af3bf461ef2a1253254af0590ebc Mon Sep 17 00:00:00 2001 From: wangggong Date: Thu, 9 Jul 2020 10:58:15 +0800 Subject: [PATCH] [parser] fix: remove warning in parser for rebuild/check/optimize/repair partition (#920) Signed-off-by: Wang Ruichao --- parser/parser.go | 6 ------ parser/parser.y | 6 ------ 2 files changed, 12 deletions(-) diff --git a/parser/parser.go b/parser/parser.go index 90235f9800..3dcf4322e2 100644 --- a/parser/parser.go +++ b/parser/parser.go @@ -10102,8 +10102,6 @@ yynewstate: ret.PartitionNames = yyS[yypt-0].item.([]model.CIStr) } parser.yyVAL.item = ret - yylex.AppendError(yylex.Errorf("The OPTIMIZE PARTITION clause is parsed but ignored by all storage engines.")) - parser.lastErrorAsWarn() } case 26: { @@ -10117,8 +10115,6 @@ yynewstate: ret.PartitionNames = yyS[yypt-0].item.([]model.CIStr) } parser.yyVAL.item = ret - yylex.AppendError(yylex.Errorf("The REPAIR PARTITION clause is parsed but ignored by all storage engines.")) - parser.lastErrorAsWarn() } case 27: { @@ -10178,8 +10174,6 @@ yynewstate: ret.PartitionNames = yyS[yypt-0].item.([]model.CIStr) } parser.yyVAL.item = ret - yylex.AppendError(yylex.Errorf("REBUILD PARTITION syntax is parsed but not implement for now.")) - parser.lastErrorAsWarn() } case 32: { diff --git a/parser/parser.y b/parser/parser.y index 0c5801481b..9482da919b 100644 --- a/parser/parser.y +++ b/parser/parser.y @@ -1561,8 +1561,6 @@ AlterTableSpec: ret.PartitionNames = $4.([]model.CIStr) } $$ = ret - yylex.AppendError(yylex.Errorf("The OPTIMIZE PARTITION clause is parsed but ignored by all storage engines.")) - parser.lastErrorAsWarn() } | "REPAIR" "PARTITION" NoWriteToBinLogAliasOpt AllOrPartitionNameList { @@ -1576,8 +1574,6 @@ AlterTableSpec: ret.PartitionNames = $4.([]model.CIStr) } $$ = ret - yylex.AppendError(yylex.Errorf("The REPAIR PARTITION clause is parsed but ignored by all storage engines.")) - parser.lastErrorAsWarn() } | "IMPORT" "PARTITION" AllOrPartitionNameList "TABLESPACE" { @@ -1637,8 +1633,6 @@ AlterTableSpec: ret.PartitionNames = $4.([]model.CIStr) } $$ = ret - yylex.AppendError(yylex.Errorf("REBUILD PARTITION syntax is parsed but not implement for now.")) - parser.lastErrorAsWarn() } | "REORGANIZE" "PARTITION" NoWriteToBinLogAliasOpt ReorganizePartitionRuleOpt {