Commit c78623fa authored by unknown's avatar unknown
Browse files

Clean up merge from 4.1


mysql-test/r/func_date_add.result:
  Update results
mysql-test/r/func_time.result:
  Update results
server-tools/instance-manager/protocol.cc:
  Fix call to list_rest()
sql/sp_head.cc:
  sp_change_db() removed, call mysql_change_db() instead.
parent d6a6a488
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -56,10 +56,10 @@ insert into t1 values (date_add('2000-01-04', INTERVAL NULL DAY));
set sql_mode='';
insert into t1 (d) select date_sub('2000-01-01', INTERVAL 2001 YEAR);
Warnings:
Warning	1437	Datetime function: datetime field overflow
Warning	1441	Datetime function: datetime field overflow
insert into t1 (d) select date_add('2000-01-01',interval 8000 year);
Warnings:
Warning	1437	Datetime function: datetime field overflow
Warning	1441	Datetime function: datetime field overflow
insert into t1 values (date_add(NULL, INTERVAL 1 DAY));
insert into t1 values (date_add('2000-01-04', INTERVAL NULL DAY));
select * from t1;
+14 −0
Original line number Diff line number Diff line
@@ -247,9 +247,13 @@ date_add("1997-12-31 23:59:59",INTERVAL -100000 DAY)
select date_add("1997-12-31 23:59:59",INTERVAL 100000 MONTH);
date_add("1997-12-31 23:59:59",INTERVAL 100000 MONTH)
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
select date_add("1997-12-31 23:59:59",INTERVAL -100000 YEAR);
date_add("1997-12-31 23:59:59",INTERVAL -100000 YEAR)
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
select date_add("1997-12-31 23:59:59",INTERVAL "10000:1" MINUTE_SECOND);
date_add("1997-12-31 23:59:59",INTERVAL "10000:1" MINUTE_SECOND)
1998-01-07 22:40:00
@@ -301,6 +305,8 @@ NULL
select date_add("9999-12-31 23:59:59",INTERVAL 1 SECOND);
date_add("9999-12-31 23:59:59",INTERVAL 1 SECOND)
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
select date_sub("0000-00-00 00:00:00",INTERVAL 1 SECOND);
date_sub("0000-00-00 00:00:00",INTERVAL 1 SECOND)
NULL
@@ -375,15 +381,23 @@ SELECT "1900-01-01 00:00:00" + INTERVAL 1<<20 HOUR;
SELECT "1900-01-01 00:00:00" + INTERVAL 1<<38 SECOND;
"1900-01-01 00:00:00" + INTERVAL 1<<38 SECOND
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
SELECT "1900-01-01 00:00:00" + INTERVAL 1<<33 MINUTE;
"1900-01-01 00:00:00" + INTERVAL 1<<33 MINUTE
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
SELECT "1900-01-01 00:00:00" + INTERVAL 1<<30 HOUR;
"1900-01-01 00:00:00" + INTERVAL 1<<30 HOUR
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
SELECT "1900-01-01 00:00:00" + INTERVAL "1000000000:214748364700" MINUTE_SECOND;
"1900-01-01 00:00:00" + INTERVAL "1000000000:214748364700" MINUTE_SECOND
NULL
Warnings:
Warning	1441	Datetime function: datetime field overflow
create table t1 (ctime varchar(20));
insert into t1 values ('2001-01-12 12:23:40');
select ctime, hour(ctime) from t1;
+1 −1
Original line number Diff line number Diff line
@@ -203,7 +203,7 @@ int send_fields(struct st_net *net, LIST *fields)
    position+= 12;
    if (my_net_write(net, send_buff.buffer, (uint) position+1))
      goto err;
    tmp= rest(tmp);
    tmp= list_rest(tmp);
  }

  if (my_net_write(net, eof_buff, 1))
+1 −1
Original line number Diff line number Diff line
@@ -737,7 +737,7 @@ sp_head::execute(THD *thd)
  if (dbchanged)
  {
    if (! thd->killed)
      ret= sp_change_db(thd, olddb, 0);
      ret= mysql_change_db(thd, olddb, 0);
  }
  m_is_invoked= FALSE;
  DBUG_RETURN(ret);