Issue 26125 - date functions ...
Summary: date functions ...
Status: CLOSED WONT_FIX
Alias: None
Product: Calc
Classification: Application
Component: code (show other issues)
Version: OOo 1.1.1RC
Hardware: All All
: P3 Trivial (vote)
Target Milestone: ---
Assignee: niklas.nebel
QA Contact: issues@sc
URL:
Keywords:
: 50460 67399 85395 116907 (view as issue list)
Depends on:
Blocks:
 
Reported: 2004-03-04 16:17 UTC by mmeeks
Modified: 2011-02-11 11:13 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
problematic sheet (18.50 KB, application/vnd.ms-excel)
2004-03-04 16:18 UTC, mmeeks
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description mmeeks 2004-03-04 16:17:37 UTC
I have a collected spreadsheet of OO.o/Excel compatibility problems; some of the
most interesting being the date problems collected at the bottom. This
spreadsheet generated using Office XP.

Date functions (OfficeXP)						
Value	MONTH	Excel	DAY 	Excel	YEAR	Exce
0	12	1	30	0	1899	1900
1	12	1	31	1	1899	1900
2	1	1	1	2	1900	1900

the columns being =MONTH(A2) etc. =DAY(A2) etc.

As you can see, at small values there appears to be a considerable disparity; is
this potentially related to zforfind.cxx's pNullDate value ? and/or why is that
constant cut/pasted into zforscan.cxx ?

Thanks.
Comment 1 mmeeks 2004-03-04 16:18:11 UTC
Created attachment 13573 [details]
problematic sheet
Comment 2 niklas.nebel 2004-03-04 19:12:06 UTC
This is a result of the infamous "date" 1900-02-29. We decided long ago not to
duplicate that behavior, and adjust the null date by a day instead. This does
mean that dates between 1900-01-01 and 1900-02-28 behave differently from Excel.
The problem with introducing that day would be that it would extend into areas
like the API, add-in functions, I18N calendar functions, or the file format. We
can't, for example, specify "ISO-8601 format date" in the file format and then
write "1900-02-29" in that case - it isn't a valid ISO date. So this has to
remain the way it is. Compatibility is important, but sanity is, too.
Comment 3 frank 2004-03-05 09:05:07 UTC
so closed
Comment 4 frank 2005-06-08 10:50:27 UTC
*** Issue 50460 has been marked as a duplicate of this issue. ***
Comment 5 niklas.nebel 2006-07-21 10:05:31 UTC
*** Issue 67399 has been marked as a duplicate of this issue. ***
Comment 6 amy2008 2008-09-17 09:22:52 UTC
*** Issue 85342 has been marked as a duplicate of this issue. ***
Comment 7 amy2008 2008-09-17 09:29:31 UTC
*** Issue 85395 has been marked as a duplicate of this issue. ***
Comment 8 niklas.nebel 2011-02-11 11:13:36 UTC
*** Issue 116907 has been marked as a duplicate of this issue. ***