# QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

cancel
Showing results for
Search instead for
Did you mean:
Creator

## One Color in my Pies

To build  a pie chart  in a Trellis Chart to show the analysis of sales and targets , for example 3 Companies 001, 002, 003. To show the % from Sales/Targets in each location. On the whole has at the moment one dimension (companies) and in my expressions (measure) Sum(Sales)/Sum (Targets) with the Property on Values % with 1 decimal. The problem is that every Pie in my Trellis Chart has one Color It should be two: one for the hole (= 100% where Sales = Targets) and one Color for the Part  (Sum(Sales)/Sum (Targets)). Sum(LineAmount) is (Sum(Sales) + Sum (Targets))

I hope someone can help me to create the right pies in my TrellisChart

Thanks in regard

2 Replies

How many measures do you have in that pie chart?

 my expressions (measure) Sum(Sales)/Sum (Targets)

That's only one: Sum(Sales)/sum(Targets)

 It should be two: one for the hole (= 100% where Sales = Targets) and one Color for the Part  (Sum(Sales)/Sum (Targets))

That's two, but what kind of measure Sales=Targets is I don't understand. Do you mean Sum( If(Sales=Targets, Sales,0)) perhaps?

 Sum(LineAmount) is (Sum(Sales) + Sum (Targets))

And here is number three: Sum(LineAmount). How does that fit in with the others in your pie chart?

Please explain in more detail what you're trying to do. Post a small qlikview document that demonstrates the problem if you can.

talk is cheap, supply exceeds demand
Creator
Author

Hello Gysbert,

The Dataset has one Amount and that is LineAmount.

Depending on the DataLevel (Actual or Targets) there is a Sum (Actual = Sales) and a Sum(Targets)

So when Sum(Sales) = Sum(Targets) my goal is reached = 100% and the whole Pie should  be GREEN.

My problem was that my pie was red. I solved the problem:

I calculate one part by:  Sum(ActualAmount) / Sum(TargetAmount)  (Format in %)

And the rest by:

If ((Sum(TargetAmount) - Sum(ActualAmount))/ Sum(TargetAmount)> 0, (Sum(TargetAmount) - Sum(ActualAmount))/ Sum(TargetAmount), 0)  (Format in %)

And it works well

Thank you for you reply

Regards Court

Community Browser