--UPDATE FROM 8.9.5.4 TO 8.9.5.5


DROP TABLE VERSION_8_9_5_4;


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

ALTER TABLE W8HP ADD W8HP_MYHOTELSHOPTRACKINGPIXEL NUMBER(1);

ALTER TABLE W8HP ADD W8HP_MYHOTELSHOPID varchar2(20);

ALTER TABLE YHKS ADD YHKS_GREENSTATUS NUMBER( 1);

COMMENT ON COLUMN YHKS.YHKS_GREENSTATUS IS 'One record in YHKS to be identified for Green Status (not used too long and review needed)';

ALTER TABLE YHKS ADD YHKS_GREENSTATUSDAYS NUMBER( 3);

COMMENT ON COLUMN YHKS.YHKS_GREENSTATUSDAYS IS 'Number of days for Green Status (not used too long and review needed)';

ALTER TABLE MMOD ADD MMOD_INCL_ADD_TO_RATE NUMBER(1);

COMMENT ON COLUMN MMOD.MMOD_INCL_ADD_TO_RATE IS 'indicates whether add to rate packages should be uploaded within the reservation rate';

ALTER TABLE MAVL ADD MAVL_UPLOAD_RATE NUMBER(1);

ALTER TABLE MAVL ADD MAVL_UPLOAD_RAVL NUMBER(1);

COMMENT ON COLUMN MAVL.MAVL_UPLOAD_RATE IS 'indicates whether the rate code is used for rate upload';

COMMENT ON COLUMN MAVL.MAVL_UPLOAD_RAVL IS 'indicates whether the rate code is used for ravl upload';

UPDATE MAVL SET MAVL_UPLOAD_RATE = 1, MAVL_UPLOAD_RAVL = 1;

ALTER TABLE XCCS ADD XCCS_CARD_ID VARCHAR2(100 CHAR);

ALTER TABLE XCCS ADD XCCS_CARD_ID_TYPE NUMBER(1);

COMMENT ON COLUMN XCCS.XCCS_CARD_ID IS 'CC token used by Best Western';

COMMENT ON COLUMN XCCS.XCCS_CARD_ID_TYPE IS 'Source of Token 1 = local interface, 2 = CRS';

ALTER TABLE MMOD ADD MMOD_ALLOW_ZERO_PRICE_PACKAGE NUMBER(1);

COMMENT ON COLUMN MMOD.MMOD_ALLOW_ZERO_PRICE_PACKAGE IS 'indicates whether an interface accepts zero rates for packages. If not the price from Suite8 will be used';

ALTER TABLE WPCA MODIFY WPCA_BARCODEREADERPORT NUMBER(2);

ALTER TABLE WPCA ADD WPCA_KIOSK_ZFST_ID NUMBER(30);

COMMENT ON COLUMN WPCA.WPCA_KIOSK_ZFST_ID IS 'Custom folio styles per Kiosk terminal';

UPDATE MMOD SET MMOD_INCL_ADD_TO_RATE = 1;

INSERT INTO WUSS(WUSS_ID, WUSS_XCMS_ID, WUSS_NAME, WUSS_VALUE)
SELECT SEQ_WUSS.NEXTVAL, 0, 'MenuCourseSeparator', '***' 
FROM DUAL
WHERE NOT EXISTS (SELECT WUSS_ID FROM WUSS WHERE WUSS_NAME='MenuCourseSeparator');

INSERT INTO WUSS(WUSS_ID, WUSS_XCMS_ID, WUSS_NAME, WUSS_VALUE)
SELECT SEQ_WUSS.NEXTVAL, 0, 'TranslationMethod', '0' 
FROM DUAL
WHERE NOT EXISTS (SELECT WUSS_ID FROM WUSS WHERE WUSS_NAME='TranslationMethod');
