Skip to main content Únase a nosotros en TDX, San Francisco o en Salesforce+ del 5 al 6 de marzo en la conferencia de desarrolladores para la era del agente de la IA. Regístrese ahora.

#Number Format0 debatiendo

Currency Format In LWC  Ex : ( 1200 = 1.2k, 1200000 = 1.2M ) 

#LWC #Currency #Number Format @Nishanth Sargunam@Suraj M

 

Currency Format In LWC Ex : ( 1200 = 1.2k, 1200000 = 1.

0/9000

Hi all, 

Is it possible to change the number format in JSON after interaction? 

Any help would be appreciated! 

3 comentarios
0/9000

Hi,

 

While I copy the dashboard JSON from sandbox and paste it in another environment (lets say production), then the number format in the charts with originally made from compare table and set number format to percent is not copied. The number format shows as simple number not the percent which was set originally.

 

Please suggest if is there any changes we can make in JSON to change the number format to percent.

 

Thanks

Nitisha

2 comentarios
  1. 2 jun 2020, 10:39 a.m.
    Thanks a lot @Peter Lyons .. I deployed the Dashboard alongwith analytics dataset metadata using change set and all formats are in place ..
0/9000

Hi, for an Einstein Analytics dashboard, is it possible to edit the format of labels in a chart (not field labels)? Sometimes they won’t display at all despite clicking ‘Preserve Labels’ under Auto Fit in the Chart settings and increasing the widget size. Also is it possible to edit the number format of a label, from say, ‘1.5k’ to display ‘1,500’? Is this something that is done by editing the JSON?

4 comentarios
  1. 21 may 2020, 9:28 p.m.
    In the chart properties, there should be a way to give the labels more room. It's a percentage field, but there is still an upper limit.
0/9000

Hi,

 

I have an issue changing the number format in our dataset(s). The new feature of choosing custom dividers doesn't seem to work. As we want to use the european number format I changed thousand separator to '.' and the decimal separator to ',' in the field menu of a lens. However when I save, the separators do not get saved (the format as such does).

 

Anyone else experiencing this, or even better knows how to change the separators?

12 comentarios
  1. 15 may 2020, 2:46 a.m.

    Also, here's the easiest workaround I found, since I hate workbench.

    Select the widget

    Click "..." and Clone query

    Add the number format on the measure directly

    Save the step (you might want to give it a friendly step name first)

    Click on the widget again and detach the query

    Drag the new query on top of the widget

    (now of course your bindings are missing, but to fix that)

    cmd-e

    Copy the new step id

    Delete the new step

    Past the new step id over the old step id

    and you should be good to go.

    FYI

    @Arthur Fabre @Dylan Thom @Anirudh Sridhar Another good use case for exposing Asset XMD in the Advanced editor.
0/9000

Hi All, 

 

Need some help with some simple number formatting. I've done a calculation between two widgets reading off the same dataset and I'm getting the right value back - however the format of the numbers isn't what I desire. It reads "362222...etc" where as i want it to just read 36.2m.

 

It won't let me access the widget anymore to change the number format via the UI, nor will it let me 'shorten the number'. 

 

Now usually i would go into the XMD file and change the format, however the dataset is a trending report and i cant seem to find an XMD file for that. 

 

So my question is how can i edit the format of the number. Here is the code for the calculation:

 

q = foreach q generate {{cell(TOTAL_PRICE_CONVERT__19.result, 0, \"sum_TOTAL_PRICE.CONVERT\").asString()}}-{{cell(TOTAL_PRICE_CONVERT__5.result, 0, \"sum_TOTAL_PRICE.CONVERT\").asString()}} as 'dif';

 

Thank you 

2 comentarios
0/9000

Hey everyone

 

I'm having a mare with the Salesforce XMD developer guides - I'm trying to update the number format in a compare table (I've added bindings already so can't do it in the table editor). 

 

I've added the below to the columns part of my query. It saves with no errors, but there's no update in the table. Not sure if maybe I've added it to the wrong place?

                        {

                            "query": {

                                "measures": [

                                    [

                                        "count",

                                        "*"

                                    ],

                                    {

                                        "format": {

                                            "customFormat": "[\"##.##%\",100]"

                                        }

                                    }

                                ],

                                "formula": "1/2"

                            }

                        }

 

Thanks!

2 comentarios
  1. 13 dic 2019, 1:00 p.m.
    Thanks Peter :) I've tried removing bindings and recreating from scratch. It seems to be removing the specified columns that's doing it, but without doing that the table doesn't show my dynamic grouping field. ah well, it still gives the gist of it!
0/9000

Hi All, any idea how to update/set number format on a compact step with bindings in dashboard json? Previous to the update I could simple add the line ,

                            "format": "percentage",

in the "query" step, this option doesn't exist anymore.

1 comentario
  1. 18 nov 2019, 2:34 p.m.
    If you change the step to a compare table it should work. Otherwise you will need SAQL and switch back and forth between derived fields. It should be easy enough to just clone the field a couple times in the dataflow and have a different format for each.
0/9000