From f4600b1f282f6a4c58dadda8196d03532fc479cf Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 17 Jan 2006 11:19:48 -0500 Subject: [PATCH] Fix for auto-partitioned tables and PARTITION BY KEY() tables --- sql/sql_partition.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/sql/sql_partition.cc b/sql/sql_partition.cc index eec66a5553e..0fc5884447c 100644 --- a/sql/sql_partition.cc +++ b/sql/sql_partition.cc @@ -1269,6 +1269,11 @@ static void check_fields_in_PF(Field **ptr, bool *all_fields, *all_fields= TRUE; *some_fields= FALSE; + if ((!ptr) || !(*ptr)) + { + *all_fields= FALSE; + DBUG_VOID_RETURN; + } do { /* Check if the field of the PF is part of the current key investigated */