关于oracle创建表提示缺失右括号

代码如下

CREATE TABLE relatrec_feat (
sect_id number(11) NOT NULL,
rel_id number(11) NOT NULL,
feat_seq number(11) NOT NULL,
feat_cat smallint(6) NULL,
daset_id number(11) NULL,
feat_sect_id number(11) NULL,
lay_id number(11) NULL,
feat_id number(11) NULL,
PRIMARY KEY(sect_id, rel_id, feat_seq)
);

提示第五行缺失右括号 就是 smallint(6)的那一行,但是去掉(6)之后就能创建了,这是为什么啊 !???

骚年,oracle里没有smallint这种类型的数据,smallint字段类型任然对应number.
温馨提示:答案为网友推荐,仅供参考
第1个回答  2013-09-06
CREATE TABLE relatrec_feat (
sect_id number(11) NOT NULL,
rel_id number(11) NOT NULL,
feat_seq number(11) NOT NULL,
feat_cat smallint NULL,
daset_id number(11) NULL,
feat_sect_id number(11) NULL,
lay_id number(11) NULL,
feat_id number(11) NULL,
PRIMARY KEY(sect_id, rel_id, feat_seq)
);本回答被网友采纳
第2个回答  2013-09-06
汗.oracle 明显有smallint类型 ,数值范围:-32,768 到 32,767 有smallint(6)范围的?
第3个回答  2013-09-06
第一次用oracle吧,这不是坑爹么。。。smallint不是oracle里面的,请使用number()
相似回答