10 Replies Latest reply: Feb 21, 2017 4:50 AM by Nicolò Cogno RSS

    Bar chart measure with sum() and aggr()

    Nicolò Cogno

      Hi everybody,

       

      I have a bar chart that shows the expenses vs the date. For each date I have objects that have been made with different quantities (I mean, each year and each day of each month the number of produced items is different). To show this, I compute the price of each object (every object is made up  of different small objects with different quantities and so I have to use sum() and Aggr()) and then I need to multiply the price by the produced quantity (I mean that maybe in one day there have been 1000 produced objcets and 700 are of a type, 300 of a different type).

       

      The problem with the chart is that editing the expression I can only get the sum of everything in the middle of the bar chart, or the prices of the objects multiplied by the total quantity and not each one multiplied by its quantity.

       

      If I use total after the sum expression I get what I want, but when I multiply by the produced quantity I get the product of the measure by the total quantity, not the quantity of each product

       

      How can I solve this?

       

      Thanks a lot for your attention

       

      Best regards

       

      Nicolò Cogno