I have a dataset column with following value
1.01 Cr
20.5 L
2.51 Cr
3.16 Cr
1.68 L
.
.
and so on
(1 Cr = 10000000, 1 L = 100000)
how do I unformat this number for example, 1.01 Cr to 10100000 and 20.5 L to 2050000
I refered this youtube video
With the newer functions currently being released we can use TEXTBEFORE and TEXTAFTER instead:
=TEXTBEFORE(A1," ")*CHOOSE(MATCH(TEXTAFTER(A1," "),{"L","Cr"},0),100000,10000000)
CodePudding user response:
What about:
=LET(X,TEXTBEFORE(A1," ")*100000,IF(RIGHT(A1)="r",X*100,X))
Or a variation that would make spilling easier (thanks @ScottCraner):
=LET(x,A1:A5,TEXTBEFORE(x," ")*10^(5 2*(RIGHT(x)="r")))