Currency formatting in bar charts

Hi friends! 

I’m making a simple bar chart showing costs in the value label and for some reason the formatting gets completely thrown off. See pictures. I am already formatting these values in the LookML and it’s working for other visualisations. I can use a table calculation to format the number and it works but I don’t want to use this since I don’t always know what currency is coming through. In my LookML I’m using html to format the number. I’m both rounding it and adding K, M etc and adding the appropriate currency symbol.

fb6a64f8-835c-45d7-bb3d-13c29731049b.png

Looking pretty ugly, see the results for how I want it to be formatted. 

42678372-9d4d-4ecc-8ab9-3eae45f8a9d3.png

Working great in another visual. 

Anyone experienced the same and how did you solve it? Is it a bug and if so how do I escalate? 

Many thanks,

Elin

0 2 1,022
2 REPLIES 2

Hi Elinvangbo,

Can you please share us more details about the current lookML code?

One workaround is to use table calculations

Looker - Condition formatting - Table calc

Hope this helps! 

Regards

Leo

Hi Leo! I tried using a table calc and that works but I can’t have that solution because it’s not dynamic. The way we’re formatting numbers are a bit complex because we don’t know what currency they will be in (this is decided in a different column). This is the LookML for the formatting: 

f52f1d3e-136d-4928-b4d3-8d078b757cc1.png
1a698a8b-1011-4e76-9fbe-8276ed0d275c.png

The currency_symbol is another field where the value is decided by mapping the currency code to a specific currency. Since the value on one row can be in euro and another in dollars I can’t use a table calc to format the number and get a currency symbol. 

Any other ideas? 

Elin

Top Labels in this Space