1 Reply Latest reply on May 12, 2021 12:07 AM by Syed Aziz

    problem case powercenter

    Álvaro Moreno Iruela New Member

      hello to all.

      I have a question about this case that I have in database and I want to pass it to powercenter, I do not know if it is better to use iif or decode for its transformation to powecenter.

      If you could help me I would appreciate it.

       

       

      CASE

      WHEN (A.COD_ECV='C') -- If agreement canceled

      THEN CASE WHEN REES.REES.COD_TYPE_REESTR='4' THEN '03'                                          

      ELSE CASE WHEN REFI.CLV_AC_PPAL IS NOT NULL THEN '04'

      ELSE CASE WHEN RECON.AC_PROVENANCE IS NOT NULL THEN '05'

      ELSE '06' 

      END

      END

      END

          ELSE

      CASE

      WHEN COD_SIT_FINAN_AC_CORE IN ('00', '01') THEN CASE WHEN VIG.CLAVEAC IS NOT NULL THEN '08' ELSE CASE

      WHEN COD_SIT_FINAN_AC_CORE='00' THEN '00' THEN '00'

      WHEN COD_SIT_FINAN_FINAN_AC_CORE='01' THEN CASE WHEN num_dia_impa <=30 THEN '01'          

      ELSE '02'                            

      END                                                                                                                                                                                                                                                                                                                               

      END

      END

      WHEN COD_SIT_FINANCIAL_AC_CORE IN ('02','03') THEN '09'

      WHEN COD_SIT_FINAN_AC_CORE = '04' THEN '07'

      ELSE '00'

      END

      END