大家晚上......我使用oracle数据建模器创建了一个模式,并尝试使用以下sql在apex中实现它
CREATE TABLE ADDRESSES
(
addressID VARCHAR2 (15 CHAR) NOT NULL ,
address_line1 VARCHAR2 NOT NULL ,
address_line2 VARCHAR2 ,
city VARCHAR2 (20 CHAR) NOT NULL ,
post_code VARCHAR2 (10 CHAR) NOT NULL ,
OWNERS_ownerID VARCHAR2 (15 CHAR) NOT NULL
) ;
ALTER TABLE ADDRESSES ADD CONSTRAINT ADDRESSES_PK PRIMARY KEY ( addressID ) ;
当我在sql命令中运行它时,它会给我ORA-00906: missing left parenthesis
当我用脚本一起运行所有内容时,它会给出DROP TABLE ADDRESSES CASCADE CONSTRAINTS ORA-00942: table or view does not exist
任何想法家伙我做错了什么?
答案 0 :(得分:1)
在域中为varchar工作错过了这里的代码
CREATE TABLE ADDRESSES
(
addressID VARCHAR2 (15 CHAR) NOT NULL ,
address_line1 VARCHAR2 (30 CHAR) NOT NULL ,
address_line2 VARCHAR2 (30 CHAR) ,
city VARCHAR2 (20 CHAR) NOT NULL ,
post_code VARCHAR2 (10 CHAR) NOT NULL ,
OWNERS_ownerID VARCHAR2 (15 CHAR) NOT NULL
) ;
ALTER TABLE ADDRESSES ADD CONSTRAINT ADDRESSES_PK PRIMARY KEY ( addressID ) ;
感谢@BhupeshC