You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
renamed new tests to include bug report id in test name:
url_script_test.sql -> url_script_test.Bug-2972.sql
date_script_test.sql -> date_script_test.Bug-2973.sql
this simplies linking tests to bug reports and vice versa
added skeleton stable output for tests url_script_test.Bug-2972 & date_script_test.Bug-2973
correct / expected output still needs to be verified and approved
Looking at the test and the code, I wonder what we think should happen.
The first test is
select str_to_date('2012','%y');
When given a format %y, the conversion function (strptime) expects a 2 digit year and returns a value for a year in the range 1969..2068. This means that in this case, the year returned is 2020 and the input string is not fully consumed.
This raises the question:
-> Should an error be returned if the input is not fully consumed? (My answer: yes.)
Furthermore, the conversion function will set the day-of-month and month both to 0. Further processing in mtime will then refuse this date as invalid (month has to be in range 1..12, day-of-month in the appropriate range for the month), and will return a date_nil value.
This raises another couple of question:
-> When given an invalid date, should the mtime module raise an error or just return nil? (My answer: it should raise an error.)
-> When the parser returns 0 for day-of-month and/or month, should we set the value to 1? (My answer: yes.)
Date: 2012-01-14 13:39:42 +0100
From: @mlkersten
To: SQL devs <>
Version: 11.7.5 (Dec2011) [obsolete]
CC: @drstmane
Last updated: 2012-02-29 10:34:27 +0100
Comment 16772
Date: 2012-01-14 13:39:42 +0100
From: @mlkersten
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:9.0.1) Gecko/20100101 Firefox/9.0.1
Build Identifier: Dec2011
The test file date_script_test.sql should be completed and tested.
Reproducible: Always
Comment 16775
Date: 2012-01-14 14:12:15 +0100
From: @drstmane
Changeset fdc3b8b379f8 made by Stefan Manegold Stefan.Manegold@cwi.nl in the MonetDB repo, refers to this bug.
For complete details, see http//devmonetdborg/hg/MonetDB?cmd=changeset;node=fdc3b8b379f8
Changeset description:
Comment 16777
Date: 2012-01-14 14:16:14 +0100
From: @drstmane
Changeset 49f931f6754f made by Stefan Manegold Stefan.Manegold@cwi.nl in the MonetDB repo, refers to this bug.
For complete details, see http//devmonetdborg/hg/MonetDB?cmd=changeset;node=49f931f6754f
Changeset description:
Comment 16804
Date: 2012-01-20 14:59:38 +0100
From: @sjoerdmullender
Looking at the test and the code, I wonder what we think should happen.
The first test is
select str_to_date('2012','%y');
When given a format %y, the conversion function (strptime) expects a 2 digit year and returns a value for a year in the range 1969..2068. This means that in this case, the year returned is 2020 and the input string is not fully consumed.
This raises the question:
-> Should an error be returned if the input is not fully consumed? (My answer: yes.)
Furthermore, the conversion function will set the day-of-month and month both to 0. Further processing in mtime will then refuse this date as invalid (month has to be in range 1..12, day-of-month in the appropriate range for the month), and will return a date_nil value.
This raises another couple of question:
-> When given an invalid date, should the mtime module raise an error or just return nil? (My answer: it should raise an error.)
-> When the parser returns 0 for day-of-month and/or month, should we set the value to 1? (My answer: yes.)
Any opnions?
Comment 16942
Date: 2012-02-19 18:20:56 +0100
From: @drstmane
date_script_test.Bug-2973.sql:
Appears to be fixed in the default branch (only) after changesets
http://dev.monetdb.org/hg/MonetDB/rev/8ee024048e42
http://dev.monetdb.org/hg/MonetDB/rev/e2d3ecc7237c
http://dev.monetdb.org/hg/MonetDB/rev/03df27701cf7
http://dev.monetdb.org/hg/MonetDB/rev/70dc90e1de2f
Remains open/failing in the Dec2011 branch.
Comment 16947
Date: 2012-02-19 18:47:07 +0100
From: @drstmane
Fixed (also) in Dec2011 by transplanting changeset 70dc90e1de2f from default to Dec2011:
http://dev.monetdb.org/hg/MonetDB/rev/ec5692ecaf8c
The text was updated successfully, but these errors were encountered: