Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Question: Howw to Sum Volume * Cost and Volume * Selling Price

Hi,

I am trying to create a "measure" in Qlik Sense Data Load Editor, and i have the following data set in my data load already.

In order to find out my total revenue, i have to use Selling price *Volume? Is there a formula which i can do that in the data load editor?

EG: How to get to total sales of ABC product in Aug ($49.50 * 88000 units)?

 

ProductFamilyCodeProductFamilyLabel                          Price                  ThePeriod
ABCABC ProductSelling Price49.58/1/2018
ABCABC ProductVolume880008/1/2018
ABCABC ProductTotal Cost per unit258/1/2018
ABCABC ProductRaw Material158/1/2018
ABCABC ProductOther material & packout108/1/2018

Thanks again.

Thomas

2 Replies
lalphonso
Partner - Contributor III
Partner - Contributor III

Hi Hin,

You will probably need to use the Generic Load statement first to "unpivot" your table on the "Label" field. Then you can use a straight formula to get the revenue.

The function is described here

The Generic Load

Regards

LA

BalaBhaskar_Qlik
Master
Master

Try something like this:

General:

....... // Initial table.

noconcatenate

ABC:

load ProductFamilyCode,

       Sum(If(Label = 'Selling Price', Price) * If(Label = 'Volume', Price)) as Value

Resident General

Group By ProductFamilyCode;