MySQL错误:Incorrect table definition;there can be only one auto column and it must be defined as a key

问题描述:MySQL建时表报错:Incorrect table definition;there can be only one auto column and it must be defined as                  a key(表格定义不正确;只能有一个自动列,并且必须将其定义为键)

错误原因:表格中有多个列设置为自动增加或者只有一个自动增加的列但是并没有将其设置为一个键

修正方式:保证自动增加的列只有一个并且将其设置为一个键




备注:该文是我在学习JavaEE时遇到问题的备忘录,只针对我创建的工程遇到的问题!!!

猜你喜欢

转载自blog.csdn.net/LQingGang/article/details/79651370
今日推荐