Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Excluding duplicates in a SUM

Hi all,

I have a dataset which returns projects and programmes from our project management system.

sometimes a project will be within 2 levels of programs

as a result if I select the top level in my QVW, it will sum up multiple instances of a project.

how can I tell it to SUM by  distinct project code

my current expression is:

SUM(BUDGET_DAYS)

I need it by distinct PROJECT_CODE

Thanks in advance,

Matt

1 Solution

Accepted Solutions
Not applicable
Author

This might work. Can you give it a try?

sum(aggr(SUM(Distinct BUDGET_DAYS), PROJECT_CODE))

Kiran.

View solution in original post

2 Replies
Not applicable
Author

This might work. Can you give it a try?

sum(aggr(SUM(Distinct BUDGET_DAYS), PROJECT_CODE))

Kiran.

Not applicable
Author

Seems to do the job very nicely thanks!!

Matt