--UPDATE FROM 8.9.4.1 TO 8.9.4.3


DROP TABLE VERSION_8_9_4_1;



/*  VERSION_8_9_4_3  */
CREATE TABLE VERSION_8_9_4_3 (
	 DUMMY	NUMBER	    NULL
)
;

CREATE TABLE ZQUE (
    ZQUE_ID NUMBER(30) NOT NULL
   ,ZQUE_ZOTA_ID NUMBER(30) NOT NULL
   ,ZQUE_MESSAGE CLOB
   ,ZQUE_RESEND NUMBER(2) NOT NULL
   ,CONSTRAINT ZQUE_PK PRIMARY KEY (ZQUE_ID) USING INDEX TABLESPACE V8INDEX) TABLESPACE V8MAIN;

CREATE SEQUENCE SEQ_ZQUE INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE NOORDER;

COMMENT ON TABLE ZQUE IS 'queue for OTA XML interface messages not sent as of issues with URL';

ALTER TABLE ZOTA ADD ZOTA_RESEND NUMBER(2,0);

COMMENT ON COLUMN ZOTA.ZOTA_RESEND IS 'number of resend tries. 0 = infinity (til successfull)';

ALTER TABLE XSCD MODIFY XSCD_FTP VARCHAR2(2000);

DELETE FROM WUSS WHERE WUSS_NAME LIKE 'BestWesternBusinessRules';

CREATE TABLE NEAT (
    NEAT_ID NUMBER(30) NOT NULL
   ,NEAT_CODE VARCHAR2(5) NOT NULL
   ,NEAT_PRODUCTNAME VARCHAR2(256) 
   ,NEAT_DEFAULT NUMBER(1) DEFAULT 0 NOT NULL 
   ,NEAT_DISPLAYORDER NUMBER(2)
   ,NEAT_ZDCO_ID NUMBER(30) NOT NULL
   ,CONSTRAINT NEAT_PK PRIMARY KEY (NEAT_ID) USING INDEX TABLESPACE V8INDEX) TABLESPACE V8CONF;
   
CREATE SEQUENCE SEQ_NEAT INCREMENT BY 1 START WITH 1000 NOMAXVALUE NOCYCLE NOCACHE NOORDER;

COMMENT ON TABLE NEAT IS 'Configuration table for Products that are used with the Europaeische.at Web Services';

COMMENT ON COLUMN NEAT.NEAT_CODE IS 'Code of the product, IN611 for example';

COMMENT ON COLUMN NEAT.NEAT_PRODUCTNAME IS 'Name of the product, Hotelstorno Plus (Vermittlerinkasso) for example, to show in the selection';

COMMENT ON COLUMN NEAT.NEAT_DEFAULT IS '1 = default, 0 = not default';

COMMENT ON COLUMN NEAT.NEAT_ZDCO_ID IS 'Link to the department code where the booked insurance fee should be posted';

ALTER TABLE XCAC MODIFY XCAC_XGCA_ID NUMBER(30) DEFAULT 0; 

ALTER TABLE YRCH MODIFY YRCH_XGCA_ID NUMBER(30) DEFAULT 0; 
