Details
-
Bug
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
10.3(EOL), 10.4(EOL), 10.5, 10.6, 10.7(EOL), 10.8(EOL), 10.9(EOL)
-
None
Description
The view created as:
CREATE TABLE t1(c1 YEAR(4)); |
INSERT INTO t1 VALUES (1901),(2155),(0000); |
CREATE VIEW v1 AS SELECT COUNT(*) AS total_rows, MIN(c1) AS min_value, MAX(c1) FROM t1; |
SELECT * FROM v1; |
DROP VIEW v1; |
DROP TABLE t1; |
gives result:
total_rows min_value MAX(c1) |
3 0000 2155
|
but view created as:
CREATE TABLE t1(c1 YEAR(4)); |
INSERT INTO t1 VALUES (1901),(2155),(0000); |
CREATE VIEW v2 AS SELECT COUNT(*) AS total_rows, MIN(c1+0) AS min_value, MAX(c1+0) FROM t1; |
SELECT * FROM v2; |
DROP VIEW v2; |
DROP TABLE t1; |
gives other result:
total_rows min_value MAX(c1+0) |
3 0 2155
|
Attachments
Issue Links
- is part of
-
MDEV-27691 make working view-protocol
- Open
- relates to
-
MDEV-28651 quote(NULL) returns incorrect result in view ('NU' instead of 'NULL')
- Closed