0 Replies Latest reply: Apr 19, 2012 7:26 AM by sievohell RSS

Set analysis: "affected amounts"

sievohell
Hi! In my QlikView file I have a few products with prices, and also projects with these same products with savings amounts, in addition to project-related dimensions that are not in the product-price tables.
The idea is to have a chart that displays the "affected costs", which is basically the sum of all costs selected by the product categories for which the savings amounts are not null. What I have come up with so far is the following:
=sum({$<Product_2_Id={"=sum(SavingsAmount)<>0"}>}Spend)
The expression basically returns the costs of the categories for which there is a project with non-zero savings (instead of non-null savings, as some "savings projects" can have a zero amount but still count towards the "affected costs"). But that problem aside, I would like to have the project-related dimensions as chart dimensions, so I can slice and dice the results. Right now, that does not work, because I let QlikView calculate the sum of all costs, which does not link to the projects table; the projects table is only referenced to see whether the product category should count towards the final sum.
Any suggestions are very much welcome! Thanks.