Skip to main content

Removing Decimal Places in CONCATENATE() Function

  • September 15, 2018
  • 4 replies
  • 48 views

Forum|alt.badge.img+1

Hi all,

I’m using the following CONCATENATE() function inside of a SWITCH() which is displaying the result below. Is there a way to remove the decimal places so that it’s only correct to two?

CONCATENATE("4 tins: ",“£”,6*26.32)
=
4 tins: £157.92000000000002

4 replies

Forum|alt.badge.img+18

@tom_pandsmarine,

My first thought is this: is the calculation “6*26.32” based on a field in your table? If so, than it would be a lot easier to refer to that field in the CONCATENATE formula.

Regards,
André


Forum|alt.badge.img+1
  • Author
  • Known Participant
  • September 15, 2018

Thanks for the replay @Andre_Zijlstra.

No, the figure on the right of the multiplication is a lookup field from another table. I’ve changed it here for clarity.


Forum|alt.badge.img+18

Thank you @tom_pandsmarine.

So, to make sure I understand it the right way: In the formula you refer to a field, and then it renders a figure you showed in the first post?


Forum|alt.badge.img+1
  • Author
  • Known Participant
  • September 16, 2018

Thank you @tom_pandsmarine.

So, to make sure I understand it the right way: In the formula you refer to a field, and then it renders a figure you showed in the first post?


That’s right @Andre_Zijlstra.

I’ve just found a workaround by using the ROUND() funtion:

CONCATENATE("4 tins: ",“£”, ROUND(6*26.32,2,0))
=
4 tins: £157.92

It going to end up being a messy formula but it works :slightly_smiling_face: