# New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
cancel
Showing results for
Did you mean:
Creator III

## Issue with totals in Table when no selections made

Hi All,

I have the following expression which works perfectly when an Order is selected and shows the correct return, however when no selections are made the total is the same on all lines and a sum total of all lines in the total.

Here is the Meaure

Sum(aggr(sum( total Aggr(Sum( distinct {<SustainableLevel = {'Sustainable'}>}Weight),Fibres) )

, "Portal Order No." )

)

Can anyone assist so that the when no selections made the lines show their correct returns.

Daniel

Labels (4)

• ### Set Analysis

1 Solution

Accepted Solutions
Champion III

Sum(Aggr( Sum( distinct {<SustainableLevel = {'Sustainable'}>}Weight) , Fibres , "Portal Order No.")))

and change total  in chart to sum of rows

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
4 Replies
Specialist II

Hi @davyqliks ,

As you have aggregated the sum on the order number that results in the getting output.

you can try below expression

Sum(sum(total Aggr(Sum( distinct {<SustainableLevel = {'Sustainable'}>}Weight),Fibres)))

Regards,
Abhijit
keep Qliking...
Champion III

Sum(Aggr( Sum( distinct {<SustainableLevel = {'Sustainable'}>}Weight) , Fibres , "Portal Order No.")))

and change total  in chart to sum of rows

Vineeth Pujari
If a post helps to resolve your issue, please accept it as a Solution.
Creator III
Author

This still returned the incorrect values:

I have been playing with the expression and found the below worked.

Really Appreciate all of your time and effort, i would not have got to the below without this help!

sum( Aggr(Sum( distinct {<SustainableLevel = {'Sustainable'}>}Weight),Fibres, "Portal Order No.") )

Creator III
Author

Hi,

Thank you so mush, by trial and error i found the same but your help is very much appreciated.

Thank you