--ABS-153093

--UNIQUEBUNDLE TABLE
ALTER TABLE UNIQUEBUNDLE ADD (CUSTOMEROWNED                   VARCHAR2(1) DEFAULT 'N' NOT NULL CONSTRAINT CUSTOMEROWNED_VALID CHECK (CUSTOMEROWNED IN ('Y', 'N')),
                              BUNDLECREATIONUSER_ID           NUMBER DEFAULT 0 NOT NULL,
                              PLANTDEPARTMENTMACHINE_ID       NUMBER DEFAULT NULL,
                              MACHINEOPERATOR_ID              NUMBER DEFAULT NULL,
                              NEWITEM                         VARCHAR2(1) DEFAULT 'N' NOT NULL CONSTRAINT NEWITEM_UB_VALID CHECK (NEWITEM IN ('Y', 'N')));
                              
CREATE INDEX XIF10UNIQUEBUNDLE ON UNIQUEBUNDLE (PLANTDEPARTMENTMACHINE_ID ASC);                   
                              
ALTER TABLE UNIQUEBUNDLE
      ADD CONSTRAINT FK_UNIQUEBUNDLE_PLANTDEPARTMENTMACHINE_ID FOREIGN KEY (PLANTDEPARTMENTMACHINE_ID)
           REFERENCES PLANTDEPARTMENTMACHINE (PLANTDEPARTMENTMACHINE_ID) ON DELETE SET NULL;
