title: ora-00906: missing left parenthesis while creating table
body: <p>I am using oracle pl.sql developer. I have two schemas, and I want to create a table from one schema in another schema. I used dbms_metadata.getddl() to retrieve the create table script. However, when i run that script in another schema, i get ORA-00906L missing left parenthesis error. Code is following:</p>
  
  <pre><code>  CREATE TABLE "DWH"."IBS_S_DOCUMENT_1" OF "DWH"."IBS_S_DOCUMENT_T_1"
   (
     CONSTRAINT "XPK_S_DOCUMENT" PRIMARY KEY ("CODE")
    USING INDEX (CREATE UNIQUE INDEX "DWH"."XPK_S_DOCUMENT" ON "DWH"."IBS_S_DOCUMENT_1"
    PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
    BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
    TABLESPACE "DWH_INDEX" )  ENABLE,
     CONSTRAINT "HSYS_005480" CHECK (DATE_ACTIV IS NOT NULL) ENABLE,
     CONSTRAINT "HSYS_005481" CHECK (DATE_CORRECT IS NOT NULL) ENABLE,
     CONSTRAINT "HSYS_005482" CHECK (CORRECTURE IS NOT NULL) ENABLE,
     CONSTRAINT "HSYS_005483" CHECK (Correcture IN ('A', 'C', 'D', 'T', 'U')) ENABLE
    ) OBJECT IDENTIFIER IS PRIMARY KEY
     PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255
   NOCOMPRESS LOGGING
    STORAGE(
      INITIAL 16384 NEXT 16384 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
    BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
    TABLESPACE "DWH_DATA"
   NESTED TABLE "IBS_S_DOCUMENT_1_H" STORE AS "IBS_S_DOCUMENT_1_HIS"
   (( PRIMARY KEY ("NESTED_TABLE_ID", "DATE_ACTIV") ENABLE)
   ORGANIZATION INDEX PCTTHRESHOLD 50
   NOCOMPRESS PCTFREE 10 INITRANS 2 MAXTRANS 255 LOGGING
    STORAGE(INITIAL 16384 NEXT 16384 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
    BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
    TABLESPACE "DWH_INDEX" ) RETURN AS VALUE
  </code></pre>
  
  <p>IBS_S_DOCUMENT_T_1 type is the following:</p>
  
  <pre><code>   CREATE OR REPLACE TYPE "IBS_S_DOCUMENT_T_1"                                          as object (
    CODE                           VarChar2(2),
    NAME                           IBS_S_DOCUMENT_1_NVT,
    DATE_ACTIV                     DATE,
    DATE_DEACT                     DATE,
    DATE_CORRECT                   DATE,
    CORRECTURE                     VarChar2(1),
    CONDITION                      VarChar2(1),
    IBS_S_DOCUMENT_1_H                   IBS_S_DOCUMENT_1_NT
  );
  </code></pre>
  
  <p>Why am i getting ora-00906 error? Can anybody help?</p>