The formula
=SPLIT("1\10/10\00002.2";"\")
doesn't result equal to
=MAP(SPLIT("1\10/10\00002.2";"\"); LAMBDA(v; v))
At the former, implicity conversion is inhibited; the latter, it takes place.
Why? Is there a way to control this?
The formula
=SPLIT("1\10/10\00002.2";"\")
doesn't result equal to
=MAP(SPLIT("1\10/10\00002.2";"\"); LAMBDA(v; v))
At the former, implicity conversion is inhibited; the latter, it takes place.
Why? Is there a way to control this?
To ensure that the result of the formula returns each part as text, use TO_TEXT:
=ArrayFormula(MAP(TO_TEXT(SPLIT("1\10/10\00002.2";"\")), LAMBDA(v; v)))
This will return
| A | B | C |
|---|---|---|
| 1 | 10/10 | 2.2 |
I have tested the above using United States, Uruguay and France as the spreadsheet locale.
Alternative
If you need to get 0002.2 instead of 2.2, add a ' before 00002.2. Depending on your specific use case, the most straightforward approach might be to add it manually or use a formula.
Formula example:
=MAP(SPLIT(SUBSTITUTE("\" &"1\10/10\00002.2", "\", "\'"),"\"), LAMBDA(v,v))
| A | B | C |
|---|---|---|
| 1 | 10/10 | 00002.2 |
{ "1", "10/10", "2.2" } instead of { "1", "10/10", "00002.2" }.=ArrayFormula(TO_TEXT(SPLIT("1\10/10\00002.2";"\"))) produces the same output.lambda(v, v) is an identity function, but it may not return the value in its original number format.
The two formulas in the question get the same result, but in different number formats. split() coerces 10/10 to the date 10/10/2025, and the map() wrapper shows that value as a dateserial.
If you want to get the three values as text, use regexextract(), like this:
=regexextract("1\10/10\00002.2", "(.+)\\(.+)\\(.+)")
This gets the three values as text in the same format they appear in the string:
{ "1", "10/10", "00002.2" }
...instead of using to_text(split()) that would coerce the values to numbers and dates first, and then converting to text, which would get this:
{ "1", "10/10", "2.2" }
See regexextract() and Working with date and time values in Google Sheets.