问题遇到的现象和发生背景
MySQL插入简单的函数索引报错
用代码块功能插入代码,请勿粘贴截图
CREATE TABLE func_index (
c1 VARCHAR(10),
c2 VARCHAR(10)
);
CREATE INDEX c2_index ON func_index ((UPPER(c2)));
运行结果及报错内容
[42000][1064] You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '(UPPER(c2)))' at line 1