summaryrefslogtreecommitdiff
path: root/sql/partition_info.cc
diff options
context:
space:
mode:
authormikael/pappa@dator5.(none) <>2006-07-21 10:23:32 -0400
committermikael/pappa@dator5.(none) <>2006-07-21 10:23:32 -0400
commit032d208be21ad47671b86ec7bec14162883e7616 (patch)
treec8d1714d195c94380bced1bb36b53a9bb474844b /sql/partition_info.cc
parent21f8aef468011654cd6f489289ee58ab06456fc9 (diff)
downloadmariadb-git-032d208be21ad47671b86ec7bec14162883e7616.tar.gz
BUG#18198: Partition function handling
Review fixes
Diffstat (limited to 'sql/partition_info.cc')
-rw-r--r--sql/partition_info.cc13
1 files changed, 7 insertions, 6 deletions
diff --git a/sql/partition_info.cc b/sql/partition_info.cc
index 94008e621c7..1afbb968547 100644
--- a/sql/partition_info.cc
+++ b/sql/partition_info.cc
@@ -718,25 +718,26 @@ bool partition_info::check_partition_info(THD *thd, handlerton **eng_type,
uint i, tot_partitions;
bool result= TRUE;
char *same_name;
- int part_expression_ok= PF_SAFE;
DBUG_ENTER("partition_info::check_partition_info");
- pf_collation_allowed= PF_SAFE;
- spf_collation_allowed= PF_SAFE;
if (check_partition_function)
{
+ int part_expression_ok= 1;
+ int pf_collation_allowed= 1;
+ int spf_collation_allowed= 1;
+
if (part_type != HASH_PARTITION || !list_of_part_fields)
{
part_expr->walk(&Item::check_partition_func_processor, 0,
(byte*)(&part_expression_ok));
- pf_collation_allowed= (char)part_expression_ok;
- part_expression_ok= PF_SAFE;
+ pf_collation_allowed= part_expression_ok;
+ part_expression_ok= 1;
if (is_sub_partitioned() && !list_of_subpart_fields)
{
subpart_expr->walk(&Item::check_partition_func_processor, 0,
(byte*)(&part_expression_ok));
}
- spf_collation_allowed= (char)part_expression_ok;
+ spf_collation_allowed= part_expression_ok;
}
if (!pf_collation_allowed ||
!spf_collation_allowed)