mirror of
https://github.com/MariaDB/server.git
synced 2025-06-03 07:02:23 +03:00
MDEV-20384 Assertion `field.is_sane()' failed in Protocol_text::store_field_metadata
This commit is contained in:
parent
da53fb6d7d
commit
1d58e62d5b
@ -587,3 +587,29 @@ DROP TABLE t1;
|
|||||||
#
|
#
|
||||||
# End of 10.4 tests
|
# End of 10.4 tests
|
||||||
#
|
#
|
||||||
|
#
|
||||||
|
# Start of 10.5 tests
|
||||||
|
#
|
||||||
|
#
|
||||||
|
# MDEV-20384 Assertion `field.is_sane()' failed in Protocol_text::store_field_metadata
|
||||||
|
#
|
||||||
|
CREATE TABLE t1 (a YEAR);
|
||||||
|
INSERT INTO t1 VALUES (2000),(2001);
|
||||||
|
SELECT MAX( NULLIF( a, 1970 ) ) AS f FROM t1;
|
||||||
|
f
|
||||||
|
2001
|
||||||
|
SELECT NULLIF(a, 1970) AS f FROM t1 ORDER BY a;
|
||||||
|
Catalog Database Table Table_alias Column Column_alias Type Length Max length Is_null Flags Decimals Charsetnr
|
||||||
|
def f 13 4 4 Y 32928 0 63
|
||||||
|
f
|
||||||
|
2000
|
||||||
|
2001
|
||||||
|
SELECT MAX(NULLIF(a, 1970)) AS f FROM t1;
|
||||||
|
Catalog Database Table Table_alias Column Column_alias Type Length Max length Is_null Flags Decimals Charsetnr
|
||||||
|
def f 8 4 4 Y 32928 0 63
|
||||||
|
f
|
||||||
|
2001
|
||||||
|
DROP TABLE t1;
|
||||||
|
#
|
||||||
|
# End of 10.5 tests
|
||||||
|
#
|
||||||
|
@ -329,3 +329,27 @@ DROP TABLE t1;
|
|||||||
--echo #
|
--echo #
|
||||||
--echo # End of 10.4 tests
|
--echo # End of 10.4 tests
|
||||||
--echo #
|
--echo #
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # Start of 10.5 tests
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # MDEV-20384 Assertion `field.is_sane()' failed in Protocol_text::store_field_metadata
|
||||||
|
--echo #
|
||||||
|
|
||||||
|
CREATE TABLE t1 (a YEAR);
|
||||||
|
INSERT INTO t1 VALUES (2000),(2001);
|
||||||
|
SELECT MAX( NULLIF( a, 1970 ) ) AS f FROM t1;
|
||||||
|
--disable_ps_protocol
|
||||||
|
--enable_metadata
|
||||||
|
SELECT NULLIF(a, 1970) AS f FROM t1 ORDER BY a;
|
||||||
|
SELECT MAX(NULLIF(a, 1970)) AS f FROM t1;
|
||||||
|
--disable_metadata
|
||||||
|
--enable_ps_protocol
|
||||||
|
DROP TABLE t1;
|
||||||
|
|
||||||
|
|
||||||
|
--echo #
|
||||||
|
--echo # End of 10.5 tests
|
||||||
|
--echo #
|
||||||
|
@ -5335,6 +5335,7 @@ public:
|
|||||||
virtual ~Type_handler_year() {}
|
virtual ~Type_handler_year() {}
|
||||||
const Name name() const override { return m_name_year; }
|
const Name name() const override { return m_name_year; }
|
||||||
enum_field_types field_type() const override { return MYSQL_TYPE_YEAR; }
|
enum_field_types field_type() const override { return MYSQL_TYPE_YEAR; }
|
||||||
|
uint flags() const override { return UNSIGNED_FLAG; }
|
||||||
protocol_send_type_t protocol_send_type() const override
|
protocol_send_type_t protocol_send_type() const override
|
||||||
{
|
{
|
||||||
return PROTOCOL_SEND_SHORT;
|
return PROTOCOL_SEND_SHORT;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user