|
View:
New views
1 Messages
—
Rating Filter:
Alert me
|
|
|
[ monetdb-Bugs-2814614 ] SQL: BC leap years handled incorrectlyBugs item #2814614, was opened at 2009-06-30 16:05
Message generated for change (Settings changed) made by boncz You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=482468&aid=2814614&group_id=56967 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: SQL/Core Group: SQL "stable" >Status: Closed >Resolution: Invalid >Priority: 2 Private: No Submitted By: gbalint (g2balint) Assigned to: Peter Boncz (boncz) Summary: SQL: BC leap years handled incorrectly Initial Comment: MonetDB handles BC timestamps, however it fails on feb 29 dates in leap years. For a non-leap year, subtracting 1 from a 03-01 timestamps works: sql>select cast('-4-03-01' as timestamp)-1; +----------------------------+ | sql_sub_single_value | +============================+ | -4-02-28 23:59:59.000000 | +----------------------------+ 1 tuple But for a leap year it returns nil: sql>select cast('-5-03-01' as timestamp)-1; +----------------------------+ | sql_sub_single_value | +============================+ | nil 23:59:59.000000 | +----------------------------+ 1 tuple You also can not instantiate it explicitly: sql>select cast('-5-02-29' as timestamp)-1; !SQLException:timestamp:conversion of string '-5-02-29' failed ---------------------------------------------------------------------- >Comment By: Peter Boncz (boncz) Date: 2009-11-11 15:31 Message: BC years are a concept that is hardly definable, as the concept of year and uniform time certainly was unknown in that age. My take is that BC years are not supported by MonetDB/SQL. ---------------------------------------------------------------------- Comment By: Stefan Manegold (stmane) Date: 2009-08-14 14:11 Message: tagged subject ---------------------------------------------------------------------- Comment By: Niels Nes (nielsnes) Date: 2009-08-06 23:08 Message: this is a problem of the mtime (monettime) module. When converting the string representation into internal values, there is a compensation for the non existing 'year zero'. This somehow changes -4 into year -3 etc. passing this to the original module writer. ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=482468&aid=2814614&group_id=56967 ------------------------------------------------------------------------------ Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day trial. Simplify your report design, integration and deployment - and focus on what you do best, core application coding. Discover what's new with Crystal Reports now. http://p.sf.net/sfu/bobj-july _______________________________________________ Monetdb-bugs mailing list Monetdb-bugs@... https://lists.sourceforge.net/lists/listinfo/monetdb-bugs |
| Free embeddable forum powered by Nabble | Forum Help |