Skip to main content
Announcements
The way to achieve your own success is the willingness to help somebody else. Go for it!
cancel
Showing results for 
Search instead for 
Did you mean: 
prasad
Contributor III
Contributor III

qlikview

Hi, I need to get one extra column as GetPercentage. This one I need to get by dividing row4/row7 etc. As there are other rows which also I need, this is an example. How to achieve this in Qlikview load script or expression. Thanks in Advance.

 

Attached is the pic image

Labels (3)
1 Solution

Accepted Solutions
prasad
Contributor III
Contributor III
Author

There are few columns, what I need eg: RowNo Column : row 4(Total4) /ColumnG(Total$)ie row 7 :

(384144.15/634425.14)*100 I need to get 60.55 next to the row4 Total Column. Pls see the image for reference. Tks! in Advance

View solution in original post

5 Replies
jonathandienst
Partner - Champion III
Partner - Champion III

How are the rows selected for the percentage?

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
MindaugasBacius
Partner - Specialist III
Partner - Specialist III

I guess that in in Front end you should you Pivot or Straight table.
In dimension add Fiscalyear.
In expressions:
1. Label Accommodation, expression = Sum({<Description = {'ACCOMMODATION'}>} Total$)
2. Label Sales, expression = Sum({<Description = {'SALES-CASH'}>} Total$)
3. Label Revenue, expression = Sum({<Description = {'TOTAL REVENUE'}>} Total$)
4. Label Accommodation %, expression = Accommodation/Sales
5. Label Sales %, expression = Sales/Revenue

Is it what you wish to achieve?
prasad
Contributor III
Contributor III
Author

There are few columns, what I need eg: RowNo Column : row 4(Total4) /ColumnG(Total$)ie row 7 :

(384144.15/634425.14)*100 I need to get 60.55 next to the row4 Total Column. Pls see the image for reference. Tks! in Advance

qliksus
Specialist II
Specialist II

May be this

Sum(totals)/below(total Sum(totals),3)

prasad
Contributor III
Contributor III
Author

I was able to resolve using set analysis. Thanks! all for the advise
=100*Sum(Count)/
If(Match(Class, 'SALES-CASH', 'DOCTOR CHARGE'), Sum(TOTAL {<Class = {'TOTAL REVENUE'}>} Count),
If(Class = 'SURGICALS & CONSUM', Sum(TOTAL {<Class = {'TOTAL COST OF SALES'}>}Count)
Services'}>}Count),
))