You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Subtask]: Support MySQL REPLACE syntax variants #24947
Support MySQL-compatible REPLACE syntax variants that MatrixOne currently rejects:
REPLACE INTO dst TABLE src
REPLACE LOW_PRIORITY INTO ...
REPLACE DELAYED INTO ...
Reference examples from the parent issue:
replace into t_table_dst table t_table_src;
replace low_priority into t_mod values(1,20);
replace delayed into t_mod values(1,30);
MySQL accepts these forms. DELAYED is converted to plain REPLACE with a warning in MySQL 8.0. MatrixOne currently rejects them in the parser.
Describe implementation you've considered
Extend the parser and AST/planner coverage for the accepted MySQL forms. LOW_PRIORITY can be parsed and ignored if MatrixOne has no equivalent scheduling behavior. DELAYED should follow the project's compatibility policy for deprecated MySQL syntax, ideally accepting it with a warning if warning infrastructure is available.
MatrixOne: git_version() = 0e8602b78
MySQL oracle: 8.0.45
Tested the three syntax variants from this issue:
replace into t_table_dst table t_table_src;
replace low_priority into t_mod values(1,20);
replace delayed into t_mod values(1,30);
Result:
REPLACE INTO dst TABLE src
MySQL: accepted and copied/replaced rows from src into dst.
MO latest main: accepted, final table result matched MySQL.
REPLACE LOW_PRIORITY INTO ...
MySQL: accepted.
MO latest main: accepted, final table result matched MySQL.
REPLACE DELAYED INTO ...
MySQL: accepted, converts it to plain REPLACE, and reports warning 3005: REPLACE DELAYED is no longer supported. The statement was converted to REPLACE.
MO latest main: statement is accepted and data is replaced successfully, but SHOW WARNINGS returns a parser-style error instead of the MySQL deprecated-syntax warning:
+-------+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Level | Code | Message |
+-------+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Error | 1064 | SQL parser error: You have an error in your SQL syntax; check the manual that corresponds to your MatrixOne server version for the right syntax to use. syntax error at line 1 column 9 near " $$"; |
+-------+------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
Conclusion: the parser no longer rejects these three forms on latest main, so the main functionality requested by this subtask appears fixed. The remaining behavior to confirm with R&D is whether REPLACE DELAYED should also emit a MySQL-compatible deprecation warning instead of the current parser-style warning entry.
Activity
Ariznawlll commentedon Jul 1, 2026
Verified on latest
origin/mainat0e8602b78.Validation environment:
Tested the three syntax variants from this issue:
Result:
REPLACE INTO dst TABLE srcsrcintodst.REPLACE LOW_PRIORITY INTO ...REPLACE DELAYED INTO ...REPLACE, and reports warning3005:REPLACE DELAYED is no longer supported. The statement was converted to REPLACE.SHOW WARNINGSreturns a parser-style error instead of the MySQL deprecated-syntax warning:Conclusion: the parser no longer rejects these three forms on latest main, so the main functionality requested by this subtask appears fixed. The remaining behavior to confirm with R&D is whether
REPLACE DELAYEDshould also emit a MySQL-compatible deprecation warning instead of the current parser-style warning entry.Ariznawlll commentedon Aug 5, 2026
motr 黑盒回归补充
已将该子任务加入 motr PR #75:
REPLACE ... TABLE的覆盖写入、列清单 +ORDER BY/LIMIT,以及LOW_PRIORITY、DELAYED和语句后会话可用性。main@607a9263616ea883ac02c052529d2aa4c62ac051连续 3/3 通过(57/57 statements)。6c0d12dfc3c3c8cab7439beaa8efb00b8349a599复现失败:REPLACE ... TABLE在 parser 阶段返回 1064。该用例能够捕获历史缺陷,已固化预期结果。