Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
gilmaioramos
Contributor III
Contributor III

Dimensão Calculada

Nobres, preciso construir uma dimensão calculada condicionada. Aonde o campo por ex. (Natureza_Evento = 'P' e EVENTO = 007; retorne o campo 'Vencimentos', e aonde o campo Natureza_Evento = 'B' e EVENTO = 007; retorne o campo 'Base ABC'

Tentei diversas formas não não retorna corretamente a ex. abaixo

=if(Natureza_Evento= 'P' and EVENTO = 007 and EVENTO = 008 and EVENTO = 053 ,'Vencimentos',

if( Natureza_Evento='B' and EVENTO=007 and EVENTO = 008 and EVENTO = 054 ,'Base ABC',

'A Classificar'))

1 Solution

Accepted Solutions
Thiago_Justen_

Gilmaio,

Teste assim:

if(Natureza_Evento= 'P' and (EVENTO = 007 or EVENTO = 008 or EVENTO = 053) ,'Vencimentos',

if( Natureza_Evento='B' and (EVENTO=007 or EVENTO = 008 or EVENTO = 054),'Base ABC',

'A Classificar'))

Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago

View solution in original post

4 Replies
Thiago_Justen_

Gilmaio,

Teste assim:

if(Natureza_Evento= 'P' and (EVENTO = 007 or EVENTO = 008 or EVENTO = 053) ,'Vencimentos',

if( Natureza_Evento='B' and (EVENTO=007 or EVENTO = 008 or EVENTO = 054),'Base ABC',

'A Classificar'))

Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago
Thiago_Justen_

Algo importante: se o  campo evento for texto, adicione aspas simples no if que te passei em cada código de evento.

Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago
gilmaioramos
Contributor III
Contributor III
Author

Deu certo!

Muito Obrigado...

Thiago_Justen_

Sempre à disposição meu caro.

Thiago Justen Teixeira Gonçalves
Farol BI
WhatsApp: 24 98152-1675
Skype: justen.thiago