~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/r/union.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:
574
574
) ENGINE=InnoDB
575
575
drop table t1;
576
576
create table t2 (it1 int, it2 int not null, i int not null, ib int, f float, d double, da date, dt datetime, sc char(10), sv varchar(10), b blob, tx text);
577
 
insert into t2 values (NULL, 1, 3, 4, 1.5, 2.5, '1972-10-22', '1972-10-22 11:50', 'testc', 'testv', 'tetetetetest', 'teeeeeeeeeeeest');
 
577
insert into t2 values (NULL, 1, 3, 4, 1.5, 2.5, '1972-10-22', '1972-10-22 11:50:00', 'testc', 'testv', 'tetetetetest', 'teeeeeeeeeeeest');
578
578
create table t1 SELECT it2 from t2 UNION select it1 from t2;
579
579
select * from t1;
580
580
it2
943
943
a
944
944
150
945
945
drop table t1;
946
 
CREATE TABLE t1 ( ID1 int NOT NULL DEFAULT '0' , ID2 datetime NOT NULL DEFAULT '0000-00-00 00:00:00' , DATA1 varchar(10) , DATA2 double(5,4) , DATA3 datetime , PRIMARY KEY (ID1,ID2));
 
946
CREATE TABLE t1 ( ID1 int NOT NULL DEFAULT '0' , ID2 datetime, DATA1 varchar(10) , DATA2 double(5,4) , DATA3 datetime , PRIMARY KEY (ID1,ID2));
947
947
CREATE TABLE t2 ( ID int NOT NULL DEFAULT '0' , DATA1 timestamp DEFAULT '0000-00-00 00:00:00' , PRIMARY KEY (ID));
948
948
(SELECT * FROM t1 AS PARTITIONED, t2 AS
949
949
PARTITIONED_B WHERE PARTITIONED_B.ID=PARTITIONED.ID1) UNION