roo-rb/roo

Excel can store dates in exponent form which causes dates to incorrectly parse to year 1900

synth opened this issue · 0 comments

synth commented

Issue

We are parsing a customer's sheet that is returning some dates in an exponential form. Eg, "4.49e4" whereas successful date parses have the form "44221.0". When a date value is returned in this exponential form, the date is parsed to a date with year 1900.

Is this expected and is this something that Roo should account for? Or is this something that should be handled at the application layer.

Steps to reproduce

I don't have a concrete way to reproduce this yet, but I can work on this following some discussion if its warranted.

System configuration

Roo version:
Tested in Roo 2.6.0 and 2.10.0

Ruby version:
2.7.5