Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Guys!
I got a data like below:
LOAD * INLINE [
a
1
2
];
LOAD * INLINE [
b, c
1, 500
2, 1000
1, 200
];
I want to sum 'c' values where 'b' equals 'a' ('a' is not selected and chart shows all possible results).
Any ideas???
Regards,
Bartosz
Here "IF" works: =Sum(If(b=a,c))
BUMP
Your question does not make sense to me. The two tables are not associated, so there is no c where b equals a, because there is no relation at all between a and b.
Hi,
Use Indirect Set Analysis.
P() will help you.
Regards,
maybe
sum({$ <b=P(a)>}c)
Thank You for quick reply Gysbert
I have tried three expressions like below
1. sum({$<b={"=b=a"}>}c)
2. sum({1<b=$::a>}c)
3. sum({$<b=p(a)>}c)
They all show result only when 'a' is selected.
Do you have any ideas what expression shoud I use instead of these or any other workaround?
Thank You very much for Your consideration,
Bartosz
Here "IF" works: =Sum(If(b=a,c))
Hi Bartosz,
Why don't you left join second table with first table on the basis of the key field ?
That's how you can have "c" field in the same table and then sum it up ,
Regards,
it works also when a isn't selected
sum({$ <b=P(a)>}c)