Skip to main content
Solved

Help on creating formula field that will add character to a word

  • September 8, 2022
  • 5 replies
  • 24 views

Hi, I want to create a formula field that will add a “$” to those number that doesn’t have that. I tried using different codes but I still haven’t achieved it, can you help me? Thank you!

Best answer by Alexey_Gusev

Hi,
another way :slightly_smiling_face:

‘$’&SUBSTITUTE({TP-PP-DollarAmount},‘$’,‘’)

5 replies

kuovonne
Forum|alt.badge.img+29
  • Brainy
  • September 8, 2022

Welcome to the Airtable community!

IF(
  LEFT( {TP-PP-DollarAmount}, 1) = "$",
  {TP-PP-DollarAmount},
  "$" & {TP-PP-DollarAmount}
)

Alexey_Gusev
Forum|alt.badge.img+25
  • Brainy
  • Answer
  • September 8, 2022

Hi,
another way :slightly_smiling_face:

‘$’&SUBSTITUTE({TP-PP-DollarAmount},‘$’,‘’)


kuovonne
Forum|alt.badge.img+29
  • Brainy
  • September 8, 2022

Hi,
another way :slightly_smiling_face:

‘$’&SUBSTITUTE({TP-PP-DollarAmount},‘$’,‘’)


Curly quotes strike again!

Thanks for sharing. I like seeing different ways to solve things in code.


  • Author
  • New Participant
  • September 9, 2022

Welcome to the Airtable community!

IF(
  LEFT( {TP-PP-DollarAmount}, 1) = "$",
  {TP-PP-DollarAmount},
  "$" & {TP-PP-DollarAmount}
)

This was really helpful. Thank you so much! :grinning_face_with_smiling_eyes:


  • Author
  • New Participant
  • September 9, 2022

Hi,
another way :slightly_smiling_face:

‘$’&SUBSTITUTE({TP-PP-DollarAmount},‘$’,‘’)


I appreciate your help, thank you so much :grinning_face_with_smiling_eyes: