开发者社区 问答 正文

MySQL InnoDB表创建联合唯一索引出错?? 400 报错

MySQL InnoDB表创建联合唯一索引出错?? 400 报错

MySQL InnoDB表创建联合唯一索引出错?

[SQL] alter table parcel add nuique index(parcel_parcelNum,parcel_status);
[Err] 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 'index(parcel_parcelNum,parcel_status)' at line 1

展开
收起
爱吃鱼的程序员 2020-05-31 00:44:57 822 分享 版权
1 条回答
写回答
取消 提交回答
  • https://developer.aliyun.com/profile/5yerqm5bn5yqg?spm=a2c6h.12873639.0.0.6eae304abcjaIB

    ALTER TABLE <span></span>table <span></span> ADD UNIQUE INDEX uniq_name (name1, name2) USING BTREE ;######好好检查语句 单词错了
    ######

    如果用navicat来操作数据库简单多了!是不是我笨多了。

    2020-05-31 00:44:58
    赞同 展开评论