mirror of
https://github.com/MariaDB/server.git
synced 2025-09-02 09:41:40 +03:00
manual merge (WL6219)
This commit is contained in:
@@ -2038,6 +2038,8 @@ hex(concat(a)) a
|
||||
30303030303030303030303030303031303030302E31 00000000000000010000.1
|
||||
drop table t1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
select hex(concat(a)) from t1;
|
||||
hex(concat(a))
|
||||
@@ -2351,6 +2353,8 @@ hex(a)
|
||||
drop table t1;
|
||||
drop view v1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
create view v1(a) as select concat(a) from t1;
|
||||
show columns from v1;
|
||||
|
@@ -2430,6 +2430,8 @@ hex(concat(a)) a
|
||||
30303030303030303030303030303031303030302E31 00000000000000010000.1
|
||||
drop table t1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
select hex(concat(a)) from t1;
|
||||
hex(concat(a))
|
||||
@@ -2743,6 +2745,8 @@ hex(a)
|
||||
drop table t1;
|
||||
drop view v1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
create view v1(a) as select concat(a) from t1;
|
||||
show columns from v1;
|
||||
|
@@ -2457,6 +2457,8 @@ hex(concat(a)) a
|
||||
30303030303030303030303030303031303030302E31 00000000000000010000.1
|
||||
drop table t1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
select hex(concat(a)) from t1;
|
||||
hex(concat(a))
|
||||
@@ -2770,6 +2772,8 @@ hex(a)
|
||||
drop table t1;
|
||||
drop view v1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
create view v1(a) as select concat(a) from t1;
|
||||
show columns from v1;
|
||||
|
@@ -3291,6 +3291,8 @@ hex(concat(a)) a
|
||||
00300030003000300030003000300030003000300030003000300030003000310030003000300030002E0031 00000000000000010000.1
|
||||
drop table t1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
select hex(concat(a)) from t1;
|
||||
hex(concat(a))
|
||||
@@ -3604,6 +3606,8 @@ hex(a)
|
||||
drop table t1;
|
||||
drop view v1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
create view v1(a) as select concat(a) from t1;
|
||||
show columns from v1;
|
||||
|
@@ -4193,6 +4193,8 @@ hex(concat(a)) a
|
||||
30303030303030303030303030303031303030302E31 00000000000000010000.1
|
||||
drop table t1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
select hex(concat(a)) from t1;
|
||||
hex(concat(a))
|
||||
@@ -4506,6 +4508,8 @@ hex(a)
|
||||
drop table t1;
|
||||
drop view v1;
|
||||
create table t1 (a year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (1);
|
||||
create view v1(a) as select concat(a) from t1;
|
||||
show columns from v1;
|
||||
|
@@ -1524,6 +1524,8 @@ DROP TABLE t1;
|
||||
# Bug#43668: Wrong comparison and MIN/MAX for YEAR(2)
|
||||
#
|
||||
create table t1 (f1 year(2), f2 year(4), f3 date, f4 datetime);
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values
|
||||
(98,1998,19980101,"1998-01-01 00:00:00"),
|
||||
(00,2000,20000101,"2000-01-01 00:00:01"),
|
||||
|
@@ -878,6 +878,8 @@ ERROR 42000: Column length too big for column 'a' (max = 255); use BLOB or TEXT
|
||||
CREATE TABLE b15776 (a char(4294967296));
|
||||
ERROR 42000: Display width out of range for column 'a' (max = 4294967295)
|
||||
CREATE TABLE b15776 (a year(4294967295));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(4294967295)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
INSERT INTO b15776 VALUES (42);
|
||||
SELECT * FROM b15776;
|
||||
a
|
||||
@@ -886,6 +888,8 @@ DROP TABLE b15776;
|
||||
CREATE TABLE b15776 (a year(4294967296));
|
||||
ERROR 42000: Display width out of range for column 'a' (max = 4294967295)
|
||||
CREATE TABLE b15776 (a year(0));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(0)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
DROP TABLE b15776;
|
||||
CREATE TABLE b15776 (a year(-2));
|
||||
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-2))' at line 1
|
||||
|
@@ -1,5 +1,7 @@
|
||||
drop table if exists t1;
|
||||
create table t1 (y year,y2 year(2));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
insert into t1 values (0,0),(1999,1999),(2000,2000),(2001,2001),(70,70),(69,69);
|
||||
select * from t1;
|
||||
y y2
|
||||
@@ -50,6 +52,8 @@ End of 5.0 tests
|
||||
# Bug #49480: WHERE using YEAR columns returns unexpected results
|
||||
#
|
||||
CREATE TABLE t2(yy YEAR(2), c2 CHAR(4));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
CREATE TABLE t4(yyyy YEAR(4), c4 CHAR(4));
|
||||
INSERT INTO t2 (c2) VALUES (NULL),(1970),(1999),(2000),(2001),(2069);
|
||||
INSERT INTO t4 (c4) SELECT c2 FROM t2;
|
||||
@@ -355,4 +359,15 @@ total_rows min_value MAX(c1)
|
||||
3 0 2155
|
||||
DROP TABLE t1;
|
||||
#
|
||||
# WL#6219: Deprecate and remove YEAR(2) type
|
||||
#
|
||||
CREATE TABLE t1 (c1 YEAR(2), c2 YEAR(4));
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
ALTER TABLE t1 MODIFY COLUMN c2 YEAR(2);
|
||||
Warnings:
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
Note 1287 'YEAR(2)' is deprecated and will be removed in a future release. Please use YEAR(4) instead
|
||||
DROP TABLE t1;
|
||||
#
|
||||
End of 5.1 tests
|
||||
|
Reference in New Issue
Block a user