Question

Transform value and aggregate

  • 28 June 2020
  • 1 reply
  • 255 views

Hi everyone 

I’m trying to put this kind of data 4.80 USD on numbers only to be able to agreggate the sum of all the USD values and calculate revenue. I’ve tried with the REGEX_EXTRACT function but i haven’t been able to get the expected result. I hope someone can help me to solve this issue. 

Thanks


1 reply

Badge

@Josecalde 

 

Can you clarify the structure of the property?

 

It seems like you have a string of “4.80 USD” and want to extract that as a number, I always find that toying around with a regex editor helps.  https://regex101.com/r/wXbcJT/1/

 

I have had some issues with escaping backslashes, so I tested with similar values in MIxpanel and using this custom property.

 

REGEX_EXTRACT(“amount”, "[0-9\\.]*")

 

Thanks

Reply


Mixpanel