VIRTUALREPORTIMPORTACAO20.03.24999998mitchellORACLEtmprod14APL-6202192.168.246.202 DIC_REL0697MP 936 - BENEFICIO EMERGENCIALRA_CSV0000T0592DIPAULNSN010 DIC_RELDINCD_ADESAOD DIC_RELDINDS_CHAPAD DIC_RELDINDS_EMPRESAD DIC_RELDINDS_REDUCAOD DIC_RELDINDT_ACORDOD DIC_RELDINNR_MESD DIC_RELSEQ2R DIC_RELENT2VR_GER_EMPRESAB8157 DIC_RELENT2VR_PES_PESFISICAC8306 DIC_RELENT2VR_RHU_FUNCIONARIOA88 DIC_RELCPO21VR_GER_EMPRESANR_CPFCNPJNNAB DIC_RELCPO22VR_RHU_FUNCIONARIOCD_CHAPANNAA DIC_RELCPO23VR_RHU_FUNCIONARIOCD_EMPFUNCNNAA DIC_RELCPO24VR_RHU_FUNCIONARIOCD_FUNCIONARIONNAA DIC_RELCPO25VR_RHU_FUNCIONARIONM_FUNCIONARIONNAA DIC_RELCPO26SIS_DUMMYDS_DADOSSNM/*BLOB*/ DIC_RELCPO27VR_PES_PESFISICANR_CPFNNAC DIC_RELCPO28VR_RHU_FUNCIONARIOTP_SITUACAONN= 1AA DIC_RELCPO29SIS_DUMMYDS_ESTENNM((SELECT {ENTER}CC.TP_CONTA{ENTER}FROM PES_PESSOACC CC,{ENTER}GER_AGENCIA AG WHERE CC.CD_PESSOA = A.CD_FUNCIONARIO AND NR_SEQUENCIA = {ENTER}({ENTER} SELECT NR_SEQCC FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA AND DT_INICIO = ( SELECT MAX(DT_INICIO) FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA){ENTER}){ENTER}AND AG.NR_BANCO = CC.NR_BANCO{ENTER}AND AG.NR_AGENCIA = CC.NR_AGENCIA{ENTER})) DIC_RELCPOFOR261'"'||1||'";' ||{ENTER} '"'||LPAD(TRIM(B.NR_CPFCNPJ),14,0)||'";' ||{ENTER} '"'||NULL ||'";'||{ENTER} '"'||TO_CHAR(A.DT_ADMISSAO,'DD/MM/YYYY')||'";'||{ENTER} '"'||LPAD(TRIM(C.NR_CPF),11,0)||'";' ||{ENTER} '"'||C.NR_PIS||'";'||{ENTER} '"'||C.NM_PESSOA||'";'||{ENTER} '"'||C.NM_MAE||'";'||{ENTER} '"'||TO_CHAR(C.DT_NASCIMENTO,'DD/MM/YYYY')||'";'|| {ENTER} '"'||@CD_ADESAO||'";' || {ENTER} '"'||@DT_ACORDO||'";' ||{ENTER} '"'||REPLACE(@DS_PERC_REDUCAO, 'ZERO', '') ||'";' ||{ENTER} '"'||@NR_MES||'";'||{ENTER}{ENTER}CASE WHEN ({ENTER}SELECT NR_SEQCC FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA AND DT_INICIO = ( SELECT MAX(DT_INICIO) FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA){ENTER}{ENTER}) IS NULL{ENTER}THEN ({ENTER}'"'|| NULL ||'";' ||{ENTER} '"'|| NULL ||'";'||{ENTER} '"'|| NULL ||'";' ||{ENTER} '"'|| NULL ||'";'||{ENTER} '"'|| NULL ||'";'||{ENTER} '"'|| NULL{ENTER}){ENTER}ELSE {ENTER}({ENTER}CASE WHEN {ENTER}((SELECT {ENTER}CC.TP_CONTA{ENTER}FROM PES_PESSOACC CC,{ENTER}GER_AGENCIA AG WHERE CC.CD_PESSOA = A.CD_FUNCIONARIO AND NR_SEQUENCIA = {ENTER}({ENTER} SELECT NR_SEQCC FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA AND DT_INICIO = ( SELECT MAX(DT_INICIO) FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA){ENTER}){ENTER}AND AG.NR_BANCO = CC.NR_BANCO{ENTER}AND AG.NR_AGENCIA = CC.NR_AGENCIA{ENTER})) > 2{ENTER}{ENTER}THEN ({ENTER}{ENTER}'"'|| NULL ||'";' ||{ENTER} '"'|| NULL ||'";'||{ENTER} '"'|| NULL ||'";' ||{ENTER} '"'|| NULL ||'";'||{ENTER} '"'|| NULL ||'";'||{ENTER} '"'|| NULL{ENTER}{ENTER}){ENTER}ELSE ({ENTER}((SELECT {ENTER}{ENTER}'"'|| CC.NR_BANCO ||'";' ||{ENTER} '"'|| CC.NR_AGENCIA ||'";'||{ENTER} '"'|| case when cc.nr_agencia is not null and AG.NR_DAC is not null then ag.nr_dac{ENTER} when cc.nr_agencia is not null and ag.nr_dac is null then '0'{ENTER} end ||'";' ||{ENTER} '"'|| CC.DS_CONTA ||'";'||{ENTER} '"'|| CC.DS_DVCTA ||'";'||{ENTER} '"'|| DECODE(CC.TP_CONTA,1,0,2,1, null) {ENTER}{ENTER}FROM PES_PESSOACC CC,{ENTER}GER_AGENCIA AG WHERE CC.CD_PESSOA = A.CD_FUNCIONARIO AND NR_SEQUENCIA = {ENTER}({ENTER} SELECT NR_SEQCC FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA AND DT_INICIO = ( SELECT MAX(DT_INICIO) FROM RHU_FUNCCC WHERE CD_EMPFUNC = A.CD_EMPFUNC AND CD_CHAPA = A.CD_CHAPA){ENTER}){ENTER}AND AG.NR_BANCO = CC.NR_BANCO{ENTER}AND AG.NR_AGENCIA = CC.NR_AGENCIA{ENTER})){ENTER}{ENTER}){ENTER}END{ENTER}){ENTER}{ENTER}END{ENTER}||'";'||{ENTER}{ENTER} (select{ENTER}'"'|| {ENTER}DECODE({ENTER}LPAD(REPLACE(TRIM( TO_CHAR(NVL(SUM(Y.VL_BASE),0),'9000000D00')),'.',''), 10, 0){ENTER}, 0000000000, '',{ENTER}LPAD(REPLACE(TRIM( TO_CHAR(NVL(SUM(Y.VL_BASE),0),'9000000D00')),'.',''), 10, 0) {ENTER}){ENTER} from RHU_FUNCMOVC X,{ENTER} RHU_FUNCMOVM Y{ENTER} where Y.CD_EMPFUNC = X.CD_EMPFUNC{ENTER} and Y.CD_CHAPA = X.CD_CHAPA{ENTER} and Y.DT_COMPETENCIA = X.DT_COMPETENCIA{ENTER} and Y.NR_SEQMOVC = X.NR_SEQMOVC{ENTER} and X.CD_EMPFUNC = A.CD_EMPFUNC{ENTER} and X.CD_CHAPA = A.CD_CHAPA{ENTER} and X.TP_SITUACAO < 6{ENTER} and X.DT_COMPETENCIA = '01/03/2020'{ENTER} and X.TP_FOLHA = 1{ENTER} and Y.CD_EVENTO IN (101)){ENTER}{ENTER}||'";'||{ENTER}{ENTER} (select{ENTER}'"'|| {ENTER}DECODE({ENTER}LPAD(REPLACE(TRIM( TO_CHAR(NVL(SUM(Y.VL_BASE),0),'9000000D00')),'.',''), 10, 0){ENTER}, 0000000000, '',{ENTER}LPAD(REPLACE(TRIM( TO_CHAR(NVL(SUM(Y.VL_BASE),0),'9000000D00')),'.',''), 10, 0) {ENTER}){ENTER} from RHU_FUNCMOVC X,{ENTER} RHU_FUNCMOVM Y{ENTER} where Y.CD_EMPFUNC = X.CD_EMPFUNC{ENTER} and Y.CD_CHAPA = X.CD_CHAPA{ENTER} and Y.DT_COMPETENCIA = X.DT_COMPETENCIA{ENTER} and Y.NR_SEQMOVC = X.NR_SEQMOVC{ENTER} and X.CD_EMPFUNC = A.CD_EMPFUNC{ENTER} and X.CD_CHAPA = A.CD_CHAPA{ENTER} and X.TP_SITUACAO < 6{ENTER} and X.DT_COMPETENCIA = '01/02/2020'{ENTER} and X.TP_FOLHA = 1{ENTER} and Y.CD_EVENTO IN (101)){ENTER}{ENTER}||'";'||{ENTER}{ENTER} (select{ENTER}'"'|| {ENTER}DECODE({ENTER}LPAD(REPLACE(TRIM( TO_CHAR(NVL(SUM(Y.VL_BA DIC_RELCPOFOR262SE),0),'9000000D00')),'.',''), 10, 0){ENTER}, 0000000000, '',{ENTER}LPAD(REPLACE(TRIM( TO_CHAR(NVL(SUM(Y.VL_BASE),0),'9000000D00')),'.',''), 10, 0) {ENTER}){ENTER} from RHU_FUNCMOVC X,{ENTER} RHU_FUNCMOVM Y{ENTER} where Y.CD_EMPFUNC = X.CD_EMPFUNC{ENTER} and Y.CD_CHAPA = X.CD_CHAPA{ENTER} and Y.DT_COMPETENCIA = X.DT_COMPETENCIA{ENTER} and Y.NR_SEQMOVC = X.NR_SEQMOVC{ENTER} and X.CD_EMPFUNC = A.CD_EMPFUNC{ENTER} and X.CD_CHAPA = A.CD_CHAPA{ENTER} and X.TP_SITUACAO < 6{ENTER} and X.DT_COMPETENCIA = '01/01/2020'{ENTER} and X.TP_FOLHA = 1{ENTER} and Y.CD_EVENTO IN (101)) {ENTER}||'"' DIC_RELREL2VR_GER_EMPRESA_VR_RHU_FUNCIONARIOVR_RHU_FUNCIONARIOCD_EMPFUNC|VR_GER_EMPRESACD_EMPRESA|N DIC_RELREL2VR_PES_PESFISICA_VR_RHU_FUNCIONARIOVR_RHU_FUNCIONARIOCD_FUNCIONARIO|VR_PES_PESFISICACD_PESSOA|N DIC_RELDEF2CD_CHAPA2Cod. ChapaSNS DIC_RELDEF2CD_EMPFUNC3Cod. EmpfuncSSS DIC_RELDEF2CD_FUNCIONARIO4Cod. FuncionarioNNS DIC_RELDEF2DS_DADOS6**Troque esta descrição pelo cabeçalho**NNN DIC_RELDEF2DS_ESTE9Ds. EsteNNN DIC_RELDEF2NM_FUNCIONARIO5Nome FuncionarioNNS DIC_RELDEF2NR_CPF7Nr. CpfNNN DIC_RELDEF2NR_CPFCNPJ1Nr. CpfcnpjNNS DIC_RELDEF2TP_SITUACAO8Tp. SituaçãoNNN