在SQL Server 2000的SQL查询分析器中输入:
create table test ( text char(5) unique);
alter table test drop unique (text)
按下F5运行
错误提示:
服务器: 消息 156,级别 15,状态 1,行 2
在关键字 'unique' 附近有语法错误。我的目的是删除test表中text字段的unique。代码照书上写的,第二行无法执行。请给我第二行的正确代码。
create table test ( text char(5) unique);
alter table test drop unique (text)
按下F5运行
错误提示:
服务器: 消息 156,级别 15,状态 1,行 2
在关键字 'unique' 附近有语法错误。我的目的是删除test表中text字段的unique。代码照书上写的,第二行无法执行。请给我第二行的正确代码。
create table test ( txt char(5) unique);
alter table test drop unique (txt)