
/*------ ATD 288115 ------*/
-- Alteracao da estrutura da tabela TRANSACAOCARTAO
DECLARE v_count NUMBER(1) := 0; 
BEGIN 
SELECT 1 INTO v_count FROM USER_TAB_COLUMNS WHERE Upper(table_name) = 'TRANSACAOCARTAO' AND Upper(column_name) = 'ATUALIZADOEM'; 
EXCEPTION 
WHEN NO_DATA_FOUND THEN 
EXECUTE IMMEDIATE 'ALTER TABLE TRANSACAOCARTAO ADD ATUALIZADOEM DATETIME '; 
END;

DECLARE v_count NUMBER(1) := 0; 
BEGIN 
SELECT 1 INTO v_count FROM USER_TAB_COLUMNS WHERE Upper(table_name) = 'TRANSACAOCARTAO' AND Upper(column_name) = 'NUMORD'; 
EXCEPTION 
WHEN NO_DATA_FOUND THEN 
EXECUTE IMMEDIATE 'ALTER TABLE TRANSACAOCARTAO ADD NUMORD INT '; 
END;