diff options
author | Mattias Jonsson <mattias.jonsson@sun.com> | 2010-03-04 11:24:39 +0100 |
---|---|---|
committer | Mattias Jonsson <mattias.jonsson@sun.com> | 2010-03-04 11:24:39 +0100 |
commit | 71cc817b2931ff1cb19a6d1adcb07b9aad85d8bb (patch) | |
tree | a7a243823bfcef9781202c526308babc11fe0a39 /sql/sql_partition.cc | |
parent | 81f857135a738436f5f03539189826e9e106fb77 (diff) | |
download | mariadb-git-71cc817b2931ff1cb19a6d1adcb07b9aad85d8bb.tar.gz |
Bug#51347: assertion with show create table + partition by columns
on decimal column
The problem was that there was no check to disallow DECIMAL
columns in the code (it was accepted as if it was INTEGER).
Solution was to correctly disallow DECIMAL columns in
COLUMNS partitioning. As documented.
Diffstat (limited to 'sql/sql_partition.cc')
-rw-r--r-- | sql/sql_partition.cc | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/sql_partition.cc b/sql/sql_partition.cc index d400e96ce7e..cfb57475b68 100644 --- a/sql/sql_partition.cc +++ b/sql/sql_partition.cc @@ -2128,8 +2128,6 @@ static int check_part_field(enum_field_types sql_type, } switch (sql_type) { - case MYSQL_TYPE_NEWDECIMAL: - case MYSQL_TYPE_DECIMAL: case MYSQL_TYPE_TINY: case MYSQL_TYPE_SHORT: case MYSQL_TYPE_LONG: @@ -2151,6 +2149,8 @@ static int check_part_field(enum_field_types sql_type, *result_type= STRING_RESULT; *need_cs_check= TRUE; return FALSE; + case MYSQL_TYPE_NEWDECIMAL: + case MYSQL_TYPE_DECIMAL: case MYSQL_TYPE_TIMESTAMP: case MYSQL_TYPE_NULL: case MYSQL_TYPE_FLOAT: |