~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/r/show_check.result

  • Committer: Jay Pipes
  • Date: 2009-02-11 04:11:47 UTC
  • mto: (873.2.13 devel)
  • mto: This revision was merged to the branch mainline in revision 878.
  • Revision ID: jpipes@serialcoder-20090211041147-f3xizbt3xo2r8n33
Fixed Field_datetime to never accept any bad datetimes as a string.  This broke
dozen or so test cases of course, which are riddled with 0000-00-00 00:00:00 crap.

Also, probably against my better judgment, I added the ability to match a string
in the following datetime expression:

YY-MM-DD HH:mm:SS

I say against my better judgment because it looks similar to the ISO 8601:1988 standard
format specifier, but is NOT since ISO always expects a 4-digit year.  But, to be compatible
with MySQL...

Show diffs side-by-side

added added

removed removed

Lines of Context:
295
295
type_timestamp timestamp not null,
296
296
type_date date,
297
297
type_time time not null default '00:00:00',
298
 
type_datetime datetime not null default '0000-00-00 00:00:00',
 
298
type_datetime datetime,
299
299
type_enum enum ('red', 'green', 'blue'),
300
300
type_set enum ('red', 'green', 'blue'),
301
301
type_blob blob,
314
314
  `type_timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
315
315
  `type_date` date,
316
316
  `type_time` time NOT NULL,
317
 
  `type_datetime` datetime NOT NULL,
 
317
  `type_datetime` datetime,
318
318
  `type_enum` enum('red','green','blue'),
319
319
  `type_set` enum('red','green','blue'),
320
320
  `type_blob` blob,
323
323
insert into t1 (type_timestamp) values ("2003-02-07 10:00:01");
324
324
select * from t1;
325
325
type_int        type_bigint     type_decimal    type_numeric    empty_char      type_char       type_varchar    type_timestamp  type_date       type_time       type_datetime   type_enum       type_set        type_blob
326
 
NULL    NULL    NULL    NULL    NULL    NULL    NULL    2003-02-07 10:00:01     NULL    00:00:00        0000-00-00 00:00:00     NULL    NULL    NULL
 
326
NULL    NULL    NULL    NULL    NULL    NULL    NULL    2003-02-07 10:00:01     NULL    00:00:00        NULL    NULL    NULL    NULL
327
327
drop table t1;
328
328
create table t1 (a int not null);
329
329
create table t2 select max(a) from t1;