Apache OpenOffice (AOO) Bugzilla – Issue 20026
Trouble handling 16 digit credit card numbers in Calc
Last modified: 2010-11-10 21:31:08 UTC
I am importing a comma-delimited .csv file that has 16 digit credit card numbers in one of the fields. When they are displayed in Calc, they are displayed in scientific notation. ie 1234567890123456 becomes 1.23+015 In the "Input Line" field, the number is displayed as: 1.234567890123456E+015 If I "Format Cells" and use "-1234" or set up a custom format code like: ################ the cells display properly ie in conventional number format. But the "Input Line" is still in the format of: 1.234567890123456E+015 Thus, when I save the file, the 16 digit credit card number is saved in scientific notation format. In addition, if I close the file and then re-open it again, I have to go through the "Format Cells" procedure again to get it to display properly. Is there any way to: 1. Set the default display to 16 digit standard numbers? 2. Save the .csv file with standard 16 digit credit card numbers as the default, rather than scientific notation? In addition, the last digit (number 16) becomes a zero and the whole number gets rounded up. ie 1234567890123456 becomes 1234567890123460 I have just downloaded OOo 1.1RC5 and it is the same.
Hi Eike, saving such document into our own format holds the numberformat but the change in the last two digits occur. What do you think ? Frank
Normal numeric rounding behavior. There just is no infinite precision in numerical computing, in fact we don't claim more than 12 significant digits to be correct. Use text input instead of raw number input, either assign a text number format to cells before entering the digits, or start the input with a single ' quote/apostrophe to force text and not have it interpreted as a number.
Hi Capstone737, have a look at Eikes comment. As Excel does it in the same way and a workaround is given, I have to close it as wontfix. Frank
closed wontfix
Just adding clarity to the workaround: As the data comes from a CSV file (and isn't manually input by keyboard means), set the corresponding column to Text in the import dialog.
Created attachment 73688