Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
Modernize Your QlikView Deployment webinar, Nov. 3rd. REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Creator III
Creator III

Block Chart Positive and negative numbers

Hi All,

I have created a block and there are positive and negative numbers. When this happens my block chart becomes like this..Image shown below

BC.PNG

Numbers image for your reference:

BC1.PNG

If i use fabs only positive values are coming but i need to display negative values also.

Expression i have written is

=(num(sum(if(isnull([Clrng doc]), [LC2 Amount])),' #,##0.00'))

Can you please help me how to get the negative numbers also.

Thanks,

Bharat

1 Solution

Accepted Solutions
Highlighted
MVP
MVP

hi

use the below expression

Dual (num(sum(if(isnull([Clrng doc]), [LC2 Amount])),' #,##0.00'),fabs(sum(if(isnull([Clrng doc]), [LC2 Amount]))))

View solution in original post

9 Replies
Creator II
Creator II

Hi,

Block chart is not allow the Negative  '-' values.

=fabs(num(sum(if(isnull([Clrng doc]), [LC2 Amount])),' #,##0.00')))

you can try this one.

you will get the positive & negative values. but here it will not show the '-' negative symbal.

Highlighted
MVP
MVP

create two expression in block chart, first with fabs & second without fabs

1) fabs(num(sum(if(isnull([Clrng doc]), [LC2 Amount])),' #,##0.00'))

2) num(sum(if(isnull([Clrng doc]), [LC2 Amount])),' #,##0.00')

Highlighted
Creator II
Creator II

kush,

I tried your logic but I am not getting the values.


can you share the example.

Highlighted
MVP
MVP

As this works for pie chart, I thought it should work for Block too, but it's not working. Need to look for another solution

Highlighted
Creator III
Creator III

thanks for your reply mani.. I have tried this expression but in Block chart  even the negative numbers are not displaying even without symbol...Can you please tell me how can i display those negative numbers also..

Highlighted
MVP
MVP

It's good that you got the solution but not exactly.

Here is how you will get the negative number on block chart.

Untitled.jpg

Highlighted
Creator III
Creator III

Thanks Kush.. Can you please send the test file... so that i can go through it and also please let me know what expressions i need to write..

Highlighted
MVP
MVP

hi

use the below expression

Dual (num(sum(if(isnull([Clrng doc]), [LC2 Amount])),' #,##0.00'),fabs(sum(if(isnull([Clrng doc]), [LC2 Amount]))))

View solution in original post

Highlighted
Creator III
Creator III

thanks Kush...