~ubuntu-branches/ubuntu/trusty/drizzle/trusty

« back to all changes in this revision

Viewing changes to tests/t/month.test

  • Committer: Bazaar Package Importer
  • Author(s): Monty Taylor
  • Date: 2010-10-02 14:17:48 UTC
  • mfrom: (1.1.1 upstream)
  • mto: (2.1.17 sid)
  • mto: This revision was merged to the branch mainline in revision 3.
  • Revision ID: james.westby@ubuntu.com-20101002141748-m6vbfbfjhrw1153e
Tags: 2010.09.1802-1
* New upstream release.
* Removed pid-file argument hack.
* Updated GPL-2 address to be new address.
* Directly copy in drizzledump.1 since debian doesn't have sphinx 1.0 yet.
* Link to jquery from libjs-jquery. Add it as a depend.
* Add drizzled.8 symlink to the install files.

Show diffs side-by-side

added added

removed removed

Lines of Context:
16
16
# Test improper argument list 
17
17
#
18
18
# 1 arg is required.
19
 
--error 1064 
 
19
--error ER_PARSE_ERROR 
20
20
# Wrong parameter count...but unfortunately produces 1064 Syntax Error due to limitations of 
21
21
# the SQL parser, which considers MONTH a keyword before being a function symbol
22
22
SELECT MONTH();
23
 
--error 1064
 
23
--error ER_PARSE_ERROR
24
24
# Wrong parameter count...but unfortunately produces 1064 Syntax Error due to limitations of 
25
25
# the SQL parser, which considers MONTH a keyword before being a function symbol
26
26
SELECT MONTH(1, 0);
30
30
# produce an error, not a NULL or anything
31
31
# else...
32
32
#
33
 
--error 1686
 
33
--error ER_INVALID_DATETIME_VALUE
34
34
SELECT MONTH("xxx");
35
35
 
36
36
# Indy, bad dates!
37
 
--error 1686
 
37
--error ER_INVALID_DATETIME_VALUE
38
38
SELECT MONTH("0000-00-00"); # No 0000-00-00 dates!...
39
 
--error 1686
 
39
--error ER_INVALID_DATETIME_VALUE
40
40
SELECT MONTH("0000-01-01"); # No zero year parts
41
 
--error 1686
 
41
--error ER_INVALID_DATETIME_VALUE
42
42
SELECT MONTH("0001-00-01"); # No zero month parts
43
 
--error 1686
 
43
--error ER_INVALID_DATETIME_VALUE
44
44
SELECT MONTH("0001-01-00"); # No zero day parts
45
 
--error 1686
 
45
--error ER_INVALID_DATETIME_VALUE
46
46
SELECT MONTH("2000-02-30"); # No Feb 30th!
47
 
--error 1686
 
47
--error ER_INVALID_DATETIME_VALUE
48
48
SELECT MONTH("1900-02-29"); # Not a leap MONTH since not divisible evenly by 400...
49
 
--error 1686
 
49
--error ER_INVALID_DATETIME_VALUE
50
50
SELECT MONTH('1976-15-15'); # No 15th month!
51
51
 
52
52
# A good date, which should output 1