Bug 881523 - xls2csv misinterprets the DATEMODE chunk
xls2csv misinterprets the DATEMODE chunk
Status: NEW
Product: Fedora EPEL
Classification: Fedora
Component: catdoc (Show other bugs)
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: Adel Gadllah
Fedora Extras Quality Assurance
Depends On:
  Show dependency treegraph
Reported: 2012-11-28 22:00 EST by Msquared
Modified: 2015-04-13 16:51 EDT (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
Patch to fix the problem (2.07 KB, patch)
2012-11-28 22:00 EST, Msquared
no flags Details | Diff
Patch for the specfile (1.55 KB, patch)
2012-11-28 22:06 EST, Msquared
no flags Details | Diff

  None (edit)
Description Msquared 2012-11-28 22:00:59 EST
Created attachment 653930 [details]
Patch to fix the problem

Description of problem:
When parsing an XLS file, xls2csv interprets the presence of DATEMODE to determine the epoch for date storage.  The correct use of the DATEMODE chunk (when present) is to inspect the value and use that to determine the epoch for date storage.

Version-Release number of selected component (if applicable):

How reproducible:

Steps to Reproduce:
1. Convert an XLS file produced with a recent version of MS Excel
2. Inspect the dates in the output CSV file
Actual results:
The dates are off by four years.

Expected results:
The dates are accurage.

Additional info:
Patch coming up!
Comment 1 Msquared 2012-11-28 22:06:26 EST
Created attachment 653931 [details]
Patch for the specfile
Comment 2 Msquared 2012-11-28 22:19:12 EST
Reference for my patch: https://www.openoffice.org/sc/excelfileformat.pdf

(see section 5.28 on page 154)
Comment 3 Robert Scheck 2015-04-13 16:51:24 EDT
I am not really sure how to verify that patch.

Note You need to log in before you can comment on or make changes to this bug.