Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

andre_tonini
Contributor II

SUM no Script

Pessoal,

       Estou fazendo a leitura de uma planilha do excel, onde preciso saber o total de horas extras durante o mês.

       No script grifado abaixo, preciso que o campo Hora_Extras_F seja na realidade SUM(Horas_Extras_F) mas não funciona no IF o sum, tem alguma outra forma?

        Exemplo eu precisaria da seguinte forma, dai funcionaria para mim
        IF(SUM(Hora_Extra_F) > 120 ,'100_PORCENTO','50_PORCENTO') AS SITUACAO_HORAS;  

1.png

Att,

André Tonini

1 Solution

Accepted Solutions
prma7799
Honored Contributor III

Re: SUM no Script

You want this in back end itself? Please share some sample app or try to use group by clause in script.

2 Replies
prma7799
Honored Contributor III

Re: SUM no Script

You want this in back end itself? Please share some sample app or try to use group by clause in script.

Re: SUM no Script

Condition works, But you need with Group By clause for Non-Aggregate fields in your Load statement.