Reputation: 960
I have a CSV that's generated from a website which, when imported has a column that looks like this
| INR 2000 |
| USD 300 |
| YEN 350 |
I would like to separate the currency symbol and the number into separate columns so that it looks like this
| INR | 2000 |
| USD | 300 |
| YEN | 350 |
Here, the symbol and the amount are in two separate columns. How do I achieve this? I tried going to Data > Split text to columns and all I get is a small popup asking me to specify a seperator. When I do, the number disappears and only the currency symbol remains. Is there anything that I am missing?
Upvotes: 0
Views: 365
Reputation: 1
You are able to paste CSV data as is into the spreadsheet and go to Data selecting Split text to columns... and even further specifying the delimiter:
Also, you can simply use keyboard shortcut combo:
LEFT ALT
+ D
+ E
And as already mentioned SPLIT
formula:
=SPLIT("l,f,x,a,s,f"; ",")
=SPLIT(A1; ",")
For a range/array it would be:
=INDEX(IFERROR(SPLIT(A1:A; ",")))
Upvotes: 0
Reputation: 2660
If after currency symbol there's space, you can use:
=split(a1," ")
or if you want to split whole column:
=ArrayFormula(iferror(split(a1:a," ")))
Upvotes: 1