SQL中先建立一个表,表中有几列,想将表的一列设为主键,怎么用sQL实现?我使用了alter table 表名add constrain primary key(列名)这样会 提示出错,也不知道是哪里错了