summaryrefslogtreecommitdiff
path: root/sql/ha_partition.h
diff options
context:
space:
mode:
authorMattias Jonsson <mattias.jonsson@oracle.com>2012-03-14 21:57:15 +0100
committerMattias Jonsson <mattias.jonsson@oracle.com>2012-03-14 21:57:15 +0100
commit5584e61f35346e14c4ebcdf6c71242adbc001900 (patch)
tree10a82396cfad57ec63fcf6272baf35e13af994e3 /sql/ha_partition.h
parenta930e4745ef87428bc3ec93369ed91656a70a257 (diff)
parent58b2147833f694d35d5fd62bb6f21923f21116b4 (diff)
downloadmariadb-git-5584e61f35346e14c4ebcdf6c71242adbc001900.tar.gz
merge of bug#1364811 into mysql-5.5
Diffstat (limited to 'sql/ha_partition.h')
-rw-r--r--sql/ha_partition.h18
1 files changed, 9 insertions, 9 deletions
diff --git a/sql/ha_partition.h b/sql/ha_partition.h
index e4e5b25e95e..220af4d4e89 100644
--- a/sql/ha_partition.h
+++ b/sql/ha_partition.h
@@ -177,6 +177,12 @@ private:
ha_rows m_bulk_inserted_rows;
/** used for prediction of start_bulk_insert rows */
enum_monotonicity_info m_part_func_monotonicity_info;
+ /** Sorted array of partition ids in descending order of number of rows. */
+ uint32 *m_part_ids_sorted_by_num_of_records;
+ /* Compare function for my_qsort2, for reversed order. */
+ static int compare_number_of_records(ha_partition *me,
+ const uint32 *a,
+ const uint32 *b);
public:
handler *clone(const char *name, MEM_ROOT *mem_root);
virtual void set_part_info(partition_info *part_info)
@@ -584,15 +590,9 @@ public:
*/
private:
- /*
- Helper function to get the minimum number of partitions to use for
- the optimizer hints/cost calls.
- */
- void partitions_optimizer_call_preparations(uint *num_used_parts,
- uint *check_min_num,
- uint *first);
- ha_rows estimate_rows(bool is_records_in_range, uint inx,
- key_range *min_key, key_range *max_key);
+ /* Helper functions for optimizer hints. */
+ ha_rows min_rows_for_estimate();
+ uint get_biggest_used_partition(uint *part_index);
public:
/*