IF OBJECT_ID('UK_EST_NF_ENT_IT_CD_EMP_CD_FILIAL_CD_NF_SEQ_ITEM') IS NULL
BEGIN 
    EXEC P_CORRIGE_SEQ_ITEM_DUPLICADO_EST_NF_ENT

    CREATE UNIQUE INDEX UK_EST_NF_ENT_IT_CD_EMP_CD_FILIAL_CD_NF_SEQ_ITEM ON EST_NF_ENT_IT (CD_EMP, CD_FILIAL, CD_NF, SEQ_ITEM)
END;