Bug 60801

Summary: Some long numbers are wrong when use POI
Product: POI Reporter: Max <b0ol>
Component: POIFSAssignee: POI Developers List <dev>
Status: NEEDINFO ---    
Severity: normal CC: dtn-asfbugs
Priority: P2    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: All   
Attachments: test excel file

Description Max 2017-03-02 10:26:25 UTC

Comment 1 Max 2017-03-02 10:35:07 UTC
I have found the wrong work of readLongLE() method in DataInputBlock.class.
If we have, for example numbers like in our excel sheet:


In POI in will be:


after transformation.
Comment 2 Nick Burch 2017-03-02 10:51:00 UTC
Are you sure this isn't just a lack of precision in the number due to insufficient bits available to store the exact value? (Most commonly also seen by people storing credit card numbers in an excel cell formatted as a number)
Comment 3 Max 2017-03-02 10:56:20 UTC
Created attachment 34794 [details]
test excel file

There aare some numbers in that text file. Some of them have string cell format and some of them - format like digits. Some of the numbers formatted like digits have wrong  representation in poi.
Comment 4 Max 2017-03-02 11:02:02 UTC
Hello, Nick. Maybe you are right. It's really big numbers that supposed to be strings. But some of them nevertheless correct treated by POI. I have attached the file with example.
Comment 5 Nick Burch 2017-03-02 11:26:58 UTC
Ping David North, our expert on this sort of thing...
Comment 6 Max 2017-03-02 11:32:57 UTC
Ok, thank you, Nick!