Quicksight - Rounding to 2 decimals

I have a requirement where I need to display %s over 4 decimal places. But on dividing the 2 numbers, Quicksight by default truncates anything beyond 2 decimals. Is there a way to change that to 4?
Check image below-

**FYI: the format data option doesn’t help-

Hi @Ops_Expert

I was able to replicate the behavior and unfortunately in SPICE currently not able to work around it.

Two things

1- if you have a database, you could overcome this by doing the math in the DB, with some custom SQL

2- We are working on functionality in SPICE to support FLOAT data types - which SHOULD help resolve this.

Have looped in @emilyzhu from product to hopefully get some more info.

Thanks!
Ramon

Unfortunately, I have to do the calculations on the fly because of multi-level aggregations by totals on the dashboard (pre-calculated values are just summaries of individual rows which isn’t correct for my use case)

I appreciate the action item you mentioned

HI @Ops_Expert , the rounding is happening in SPICE since we currently support fixed (18,4) decimal datatype. As Ramon mentioned, we are working to enable FLOAT type, which would allow in total 16 digit but with a floating decimal point. It will provide much wider flexibility to store numerial data type.
For now, you can try to use Direct Query mode, which will honor your data source capability for decimal places.

2 Likes

I only use direct SPICE import for analysis, as direct import isn’t allowed due to privacy concerns. I was able to just use multiplication by 100.0000 with number format and it works fine. Though, I do hope the feature is released soon.

1 Like

Hi @Ramon_Lopez and @emilyzhu, are there any updates on enabling FLOAT dtypes in SPICE? When is the expected roll-out?

Hi @Nicolas

Beta/preview very soon. Please Direct Message me (in private) you QuickSight account name + account number + email and i can add you to the preview so when it comes out you can test it out.

thanks!
Ramon

3 Likes

Hi @Ramon_Lopez - I’m working with a lot of blockchain data which requires both very large numbers but also handling of a lot of decimal places. I am bumping into the 18,4 issue everywhere… would welcome an opportunity to beta test a version of SPICE that can handle such data. Thanks in advance!

@Ramon @emilyzhu Hello,

Do you have any update on when the SPICE is going to allow float ?

Thanks,

Hi @helene.besancon Not sure if you have already connected with Ramon. If not, you may want to Direct Message @Ramon_Lopez following the protocols he lists above to see if you can be added to the preview.

Hi @helene.besancon

Please DIRECT MESSAGE me your accountID, account name, region and description of the use case and happy to add you to the preview.

thanks!
Ramon Lopez

1 Like

Hi Ramon,

This is also a feature that is highly appreciated within my organisation. Is the preview in a seperate environment, or will it be enabled within my quicksight environment?

Hi @dave.osa1

Preview can be enabled in your dev account once providing the requested account details.

Thanks
Ramon

1 Like

Any idea when this issue will be resolved in QS?

@Saranya_Pandiaraj - I have one suggestion which you can try out and let me know if that works. Please try to forcefully convert the decimal datatype to double by converting any of the operands using the (^ 1) operation. Trying to provide an example below. Let me know if that works! Thank you!

Original Calculation (It was giving wrong value)

image

Updated Calculation (Accurate Value with correct precision)

image

2 Likes

It’s not working for me :frowning:

Hi @Saranya_Pandiaraj

As mentioned above- this new capability is currently in preview and should be release max in a few months.

If you would like to test via a dev account- i can enable preview on your account. Otherwise the feature will be released soon.

DM to enable in your development account if interested.

thanks!
Ramon Lopez

1 Like

I must be blind. But where can i send my AWS account credentials through direct message?

@dave.osa1

I’ll send you a Direct Message. You should see a notification in the top right icon on the community.

2 Likes

Thanks @Ramon_Lopez for this follow up with @dave.osa1. :slight_smile: