
/*------ ATD 407990 ------*/
DECLARE v_count NUMBER(1) := 0; 
BEGIN 
SELECT 1 INTO v_count FROM USER_TAB_COLUMNS WHERE Upper(table_name) = 'TABROTECAD' AND Upper(column_name) = 'VALMINIMOFRETE'; 
EXCEPTION 
WHEN NO_DATA_FOUND THEN 
EXECUTE IMMEDIATE 'ALTER TABLE TABROTECAD ADD VALMINIMOFRETE NUMBER(15,2) NULL '; 
END;
/
DECLARE v_count NUMBER(1) := 0; 
BEGIN 
SELECT 1 INTO v_count FROM USER_TAB_COLUMNS WHERE Upper(table_name) = 'TIPOFRETE' AND Upper(column_name) = 'FRETEPADRAO'; 
EXCEPTION 
WHEN NO_DATA_FOUND THEN 
EXECUTE IMMEDIATE 'ALTER TABLE TIPOFRETE ADD FRETEPADRAO INT DEFAULT 0 NOT NULL '; 
END;
/