Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I'm going to try to explain my issue, but I know it will be a little abstract. For the following table:
| Product | Cost | Input Die |
|---|---|---|
| MSM9615 | $20 | Saturn |
| Saturn | $5 | N/A |
I want a bar chart that sums up the cost by product, but if there is an Input Die associated with the Product, I would also like to find that cost and aggregate it. So, "Input Die" is not only a text attribute to "Product", but also a "Product" itself. Ideally, I would have a bar chart with MSM9615 cost = $25 (because its Product cost is $20 and its Input Die cost is $5).
How can I do this? Should I approach it in the chart expression or in the script editor?
Thank you!!
Susan
I would handle this in the script by loading the table again, adding another column for the cost associated with the input die. Something like:
Fact:
LOAD Product,
Cost,
InputDie
FROM Table;
LEFT JOIN (Fact)
LOAD Product AS InputDie,
Cost AS InputDieCost
FROM Table;
Then you could create an expression that adds the columns together for your bar chart.