# Qlik Sense App Development

Announcements
See why Qlik is recognized as a Leader for the 10th year in a row – and discover how Qlik can help put your business in the lead. Get Report
Highlighted
New Contributor II

## Set Analysis Pricing

Dear Community,

I am struggling with my calculation. What I have is a list of Options and their respective price. Also I know how many of them were sold. So I want to cumulate this Sales.

I tried this approach : Sum({\$<[Price] -= '0'>} [Price]*Quantity)

But it doesn't work properly! I attached an excel as an example.

I would be happy for your help.

Regards, Alex

1 Solution

Accepted Solutions
Highlighted
MVP

## Re: Set Analysis Pricing

Try this

`Sum({\$<[Price] -= {'0'}>} [Price]*Quantity)`
9 Replies
Highlighted
MVP

## Re: Set Analysis Pricing

Try this

`Sum({\$<[Price] -= {'0'}>} [Price]*Quantity)`
Highlighted

## Re: Set Analysis Pricing

Try this as well, Make sure whether you have applied correct field

Sum(If(Price <> '0', Price*Quantity))

Or

Sum({<Price = {"=Sum(Price)<>0"}>} Price*Quantity)

Before develop something, think If placed (The Right information | To the right people | At the Right time | In the Right place | With the Right context)
Highlighted
New Contributor II

## Re: Set Analysis Pricing

Thank you @sunny_talwar and @Anil_Babu_Samineni!

Both solutions work excellent for me.

Highlighted
New Contributor II

## Re: Set Analysis Pricing

Hi,

the number seemed a little bit too high actually.

So I exported my table to Excel. And when I sum up there I get a much lower number. How can that be?

Would be thankful for help.

Highlighted
MVP

## Re: Set Analysis Pricing

Would you be able to share a sample to show the issue?
Highlighted
New Contributor II

## Re: Set Analysis Pricing

I cant share my initial data because it is sensitive. And when I simplify the data it works. So there must me something wrong in my data. I am sure the formula works right.
Highlighted
MVP

## Re: Set Analysis Pricing

@alexsid-qlik wrote:
I cant share my initial data because it is sensitive. And when I simplify the data it works. So there must me something wrong in my data. I am sure the formula works right.

In that case, I am not really sure how to help you... I mean I need to see something before I can see what might be going on.

Highlighted
New Contributor II

## Re: Set Analysis Pricing

ok i found my mistake. I had a wrong Where statement in my load script.
Highlighted
MVP

Great 🙂