Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
kunkumnaveen
Specialist
Specialist

how to get percentage on bars

Hello All,

is it possible to show both value and percentage on each bar in bar chart..

dimension:category ,decision

expression i wrote :=count({$<Category={'Smelting'},MaterialName=,YEAR=,QUATERS=,name1=,ENSTEHDAT={">=$(vFromdate)<=$(vTodate)"}>}PRUEFLOS)

i am able to get value on each bar now i need percentage of each bar from total .As you see in screen short total is:50718, and this value is divided in to three diff bars    1)43512

                                                  6626

                                                    580

                                              50718

i tried by enable relative option but i get only percentage but i need both value and percentage ,

shall i write another expression for percentage and change chart to combo chart will it work?

thanks

naveen

1 Solution

Accepted Solutions
kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

To achieve this you need to use the combo chart. See the attachment.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!

View solution in original post

22 Replies
Chanty4u
MVP
MVP

u can try (ur exp/100  ) '%'

nd in number tab  chk show in percentage

kunkumnaveen
Specialist
Specialist
Author

HI,i need value and percentage on each bar so should i need to write two expression or one ,is it possible to achieve both in one expression in bar chart

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

To achieve this you need to use the combo chart. See the attachment.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Chanty4u
MVP
MVP

did u chk fr ur expressions    .check that option and give a tryrelative.PNG

kunkumnaveen
Specialist
Specialist
Author

HI

I was guessing that ,can you help me with the  second expression the percentage one and want i need to disable because for second expression i just need values i need to show any line kind of thing 

kkkumar82
Specialist III
Specialist III

Hi Naveen you can use Dual function for in the expression as

eg

Dual(Sum(Sales) & chr(10) & Sum(Sales) / Sum(Total Sales), Sum(Sales))

The part of expression in bold is what you see on the bars and the bars use in the Y axis the maroon expression,

or you may also use a combo with two expression and one of them invisible as others suggested.

Thanks

Kiran Kumar

kunkumnaveen
Specialist
Specialist
Author

i did that ,when i enable i am getting only percentage but i need both

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Naveen,

If you look my attachment.

What I have done is I have used two expressions, one to get values and one to get percentage.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Chanty4u
MVP
MVP