When importing from a .csv file, I set “Column type” to “Text” for a column, yet the resulting cells have General Number format, not Text, unless the data in the particular cell looked like a number. I do not have “Detect special numbers” checked.
Isn’t this a bug?
I want all cells in a particular column have “Text” format regardless of their content, so that if the user later changes a cell to something like 01234 it will not be corrupted by being treated as a number and loosing the leading zero.
Here is an example. Create a .csv file:
(echo "foo,bar"; echo "0011,88/12/1") >demo.csv
Then run localc demo.csv
.
In the import dialog, un-check all options except “Separated by Comma”.
Select each column in the “Fields” and set the drop-down to Text.
Click OK.
In the resulting spreadsheet, rightclick->Format Cells… (Numbers tab) to see the format assigned. Only cell A2 has “Text” format, the other three have “General Number” format.
Is there a way to force them all to be “Text” in the import dialog?
(I can’t manually fix the cell formats after importing because in the real application I’m doing batch imports using unoconv
with the appropriate FilterOptions)