preventig numbers ending in zero from converting to scientific notation when exporting to csv

I need to convert a sheet with a column of of 16 digit numbers to a csv file and keep the numbers formatted in plain text. ive formatted the column as text.

When I export to the data into a csv file, most of the cells in the column are unaffected, but numbers that end in zero convert to scientific notation. I would like to prevent the conversion to scientific notation for the numbers ending in zero.

Posted on Aug 25, 2022 02:10 AM

Reply
Question marked as Top-ranking reply

Posted on Aug 25, 2022 03:33 PM

You could try padding those "numbers" with a leading or trailing space character or non-numeric character and see if that makes any difference. I do not know how this will affect whatever those "numbers" are being used for but, hopefully, it will force your app to treat them as text.


This is what I see going on:


The CSV is not the problem. The CSV will have the characters that make up those numbers; the same characters you see on the screen. You can view the CSV file with TextEdit to see what it looks like. It will not have it in scientific notation.


I am not familiar with what you are using to view/read the CSV but it appears to me that it is the problem. My guess is that the second number is being treated differently because it has 15 digits followed by a 0 vs the first one that has a non-zero 16th digit. 15 digits is an acceptable number (16 digits is not) so the app being used to view the CSV is dropping the trailing 0 and turning it into an exponential number. It is treating the 16 digit "number" as text




Similar questions

7 replies
Question marked as Top-ranking reply

Aug 25, 2022 03:33 PM in response to travi7997

You could try padding those "numbers" with a leading or trailing space character or non-numeric character and see if that makes any difference. I do not know how this will affect whatever those "numbers" are being used for but, hopefully, it will force your app to treat them as text.


This is what I see going on:


The CSV is not the problem. The CSV will have the characters that make up those numbers; the same characters you see on the screen. You can view the CSV file with TextEdit to see what it looks like. It will not have it in scientific notation.


I am not familiar with what you are using to view/read the CSV but it appears to me that it is the problem. My guess is that the second number is being treated differently because it has 15 digits followed by a 0 vs the first one that has a non-zero 16th digit. 15 digits is an acceptable number (16 digits is not) so the app being used to view the CSV is dropping the trailing 0 and turning it into an exponential number. It is treating the 16 digit "number" as text




Aug 25, 2022 08:54 PM in response to travi7997

The scientific notation format is likely being applied by the receiving app. It's not a function of how Numbers exports, or of the csv data itself.


So I would look into how to format numbers on the receiving end. It's probably just a matter of a few clicks. It may even be just a matter of widening the column a little.


SG



This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

preventig numbers ending in zero from converting to scientific notation when exporting to csv

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.