Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
avishaiz
Contributor III
Contributor III

Problems with sum

Hi

i have a data set of production that i am doing some calculation and i need to show the sum by month

here is the data sample:

         

PRDDATEPRODPOOLITEMIDQTYSCHEDQTYGOODTIMENORMALIZATIONTIME/NORMALIZATION
PRD0006735201/01/2017205D26-02GNPC-001223056
PRD0006735601/01/2017205D26-02GNPC-001113056
PRD0006849601/01/2017205CR3000000-01BTXH-0195951553
PRD0007096502/01/2017205D26-04A1XH-001303060512
PRD0007096801/01/2017205D26-04A1XF-001404060512
PRD0007104102/01/2017325RP500-34BTN5-006200200150.6722.39
PRD0007118301/01/2017205CR2000000-06G0NB-01551553
PRD0007118502/01/2017325RP500-34BTN5-006200200150.6722.39
PRD0007133802/01/2017205CR3000000-10R0XH-01441553
PRD0007252402/01/2017205NR4020NS-02NTPR-0025050551
PRD0007282901/01/2017100252-050002NR-FG200117505
PRD0007320502/01/2017200242-2606PC-FF12036551
PRD0007329901/01/2017205D26NS-06R2XH-0012260512
PRD0007349401/01/2017205VB60-12N1XI-00411050

when i try to get the sum of prodpool by month i cant seem to get it when i remove the PRD from the table

DATE by MONTHPRODPOOLQTYSCHEDQTYSCHED*TIME/NORMALIZATION
JAN 20172014,63027,089
JAN 20173031,21549,977
JAN 2017327,67148,764

can someone help?

16 Replies
Not applicable

HI,

Sum of Normalization is zero  for Prod Pool 10 and any thing divide by zero is undefined.

Regards,

Nandkishor Pandirkar

avishaiz
Contributor III
Contributor III
Author

maybe for a single line but not all of them

avishaiz
Contributor III
Contributor III
Author

i need the calculation for each row of PRD and then to sum all the results

avishaiz
Contributor III
Contributor III
Author

i do the calculation for each line of PRD

i take the QTYSCHED*TIME/NORMALIZATION

I want the total to be the total for each month and for each prodpool

OmarBenSalem

Use


(Sum(QTYSCHED)*sum(TIME))/sum(NORMALIZATION)



and see what happens

avishaiz
Contributor III
Contributor III
Author

i get crazy numbers

kkkumar82
Specialist III
Specialist III

May be you can write a if condition if Normalization is 0 then the expression is 0