-- ------------------------------------------
-- system client details in APM landascape --
---------------------------------------------
ALTER TABLE `cehior_auth_system_descr` 
	CHANGE COLUMN `client` `client` CHAR(3) CHARACTER SET 'utf8mb4' COLLATE 'utf8mb4_unicode_ci' NOT NULL AFTER `system`,
	CHANGE COLUMN `system` `system` CHAR(3) CHARACTER SET 'utf8mb4' COLLATE 'utf8mb4_unicode_ci' NOT NULL ,
ADD COLUMN `created` TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP AFTER `createdby`;

-- ------------------------------------------
-- APM-2521                                --
-- APM: All settings that are system       --
-- specific should be made                 --
-- project specific instead                --
-- ------------------------------------------
ALTER TABLE `cehior_auth_proj_header` 
	ADD COLUMN `su53_description` INT(1) NOT NULL DEFAULT '0' AFTER `fast`,
	ADD COLUMN `su53_extissueno` INT(1) NOT NULL DEFAULT '0' AFTER `su53_description`,
	ADD COLUMN `su53_testcase` INT(1) NOT NULL DEFAULT '0' AFTER `su53_extissueno`;

SET SQL_SAFE_UPDATES = 0;
	UPDATE cehior_auth_proj_header SET su53_description = 2 WHERE force_description = 'X';
SET SQL_SAFE_UPDATES = 1;

ALTER TABLE `cehior_auth_proj_header` 
	DROP COLUMN `force_description`;
