20 Replies Latest reply: Dec 5, 2017 4:40 AM by aparna v

# How to display data in crores and lacs format in measure of barchart?

so this is the condition :

if(912000000>10000000, Num(912000000/10000000, '###.##') & 'Crores', Num(912000000/100000, '###.##') & 'Lacs')

this expression helps me to convert value label from million to crores but its not displaying in barchart

Example (output):

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Hi Pranav,

Try:

=NUM(if(912000>10000000, 912000/10000000, 912000), if(912000>10000000, '###.## Crores', '###.### Lacs'))

probably change 912000000 to the corresponding fieldname of course.

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Hi,

Not sure on why you are doing the 912000000>10000000 part as it will always be true, but to display

Make sure you do your division in the the expression. Then Change number fomat to custom and add your form '###.## Crores' in the Format Pattern.

Mark

• ###### Re: How to display data in crores and lacs format in measure of barchart?

but it would display the wrong value it will simply append crore behind every value,

above expression will check if the value is in lacs or crores, and based on the value check it will remove zeros and displays the value

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Hi Pranav

try using the money() funktion insted if num(),

/Teis

• ###### Re: How to display data in crores and lacs format in measure of barchart?

that doesn't work because i want to divide the value by 1 lac if its less than crore and if its in crore i'll divide the value by 1crore and based on the value check lac/crore tag is appended to the end of value.. i hope know you understand my problem

• ###### Re: How to display data in crores and lacs format in measure of barchart?

For Lakhs you can use Num(912000000/100000, '###.##')  as Num(912000000/100000,'0.00L')

• ###### Re: How to display data in crores and lacs format in measure of barchart?

that works for KPIs only and not in barchart..

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Which dimension and measure are you using in bar chart? Can you please specify.

• ###### Re: How to display data in crores and lacs format in measure of barchart?

my dimension is ID and in measure i've written this expression:

if(Sum(Salary*10)>10000000, Num(Sum(Salary*10)/10000000, '###.##') & 'Crores', Num(Sum(Salary*10)/100000, '###.##') & 'Lacs')

• ###### Re: How to display data in crores and lacs format in measure of barchart?

if(Sum(Salary*10)>10000000, Num(Sum(Salary*10)/10000000, '###.##') , Num(Sum(Salary*10)/100000, '###.##') )

For me its showing bars properly.

• ###### Re: How to display data in crores and lacs format in measure of barchart?

but i want that crore and lac tags , thats the main purpose i'm using this expression..

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Can you try this and let me know,

if(Sum(Salary*10)>10000000, Num(Sum(Salary*10)/10000000, '#,##0.00C') , Num(Sum(Salary*10)/100000, '0.00L') )

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Yess i tried that also , is it showing that C and L in your output??

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Yes.

• ###### Re: How to display data in crores and lacs format in measure of barchart?

it isnt working in my dashboard , maybe because i'm using November 2017 version , can u send me your qvf file please??

thanks for helping..

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Try formatting->Custom and give this #,##0.00C as format pattern

• ###### Re: How to display data in crores and lacs format in measure of barchart?

ohh so thats how you are getting C at the end of your value, that's wrong because it will append C at the end of every value be it 8.38 lacs or 8.38 crores. your output is wrong...

• ###### Re: How to display data in crores and lacs format in measure of barchart?

I have used the expression as measure. I suggested another workaround for crores if you want values to be expressed as crores only.

• ###### Re: How to display data in crores and lacs format in measure of barchart?

No no it doesn't work that way , u didn't understand the problem ,

some bars in my data shows value in lacs and some bar's value is greater than crore .. so your solution will show all the values in crore.

• ###### Re: How to display data in crores and lacs format in measure of barchart?

Goto number formatting->measure expression