#At file:///home/msvensson/mysql/7.0/ based on revid:magnus.blaudd@stripped
3741 Magnus Blåudd 2010-09-01
ndb
- move the 'include_partition_fields_in_used_fields' function into the only file
where it's used - ha_ndbcluster.cc
- reduce MCP
modified:
sql/ha_ndbcluster.cc
sql/mysql_priv.h
sql/sql_partition.cc
=== modified file 'sql/ha_ndbcluster.cc'
--- a/sql/ha_ndbcluster.cc 2010-08-30 08:32:48 +0000
+++ b/sql/ha_ndbcluster.cc 2010-09-01 08:44:41 +0000
@@ -5134,6 +5134,34 @@ print_value:
}
+/*
+ Set fields in partition functions in read set for underlying handlers
+
+ SYNOPSIS
+ include_partition_fields_in_used_fields()
+
+ RETURN VALUE
+ NONE
+
+ DESCRIPTION
+ Some handlers only read fields as specified by the bitmap for the
+ read set. For partitioned handlers we always require that the
+ fields of the partition functions are read such that we can
+ calculate the partition id to place updated and deleted records.
+*/
+
+static void
+include_partition_fields_in_used_fields(Field **ptr, MY_BITMAP *read_set)
+{
+ DBUG_ENTER("include_partition_fields_in_used_fields");
+ do
+ {
+ bitmap_set_bit(read_set, (*ptr)->field_index);
+ } while (*(++ptr));
+ DBUG_VOID_RETURN;
+}
+
+
int ha_ndbcluster::index_init(uint index, bool sorted)
{
DBUG_ENTER("ha_ndbcluster::index_init");
=== modified file 'sql/mysql_priv.h'
--- a/sql/mysql_priv.h 2010-06-16 20:49:05 +0000
+++ b/sql/mysql_priv.h 2010-09-01 08:44:41 +0000
@@ -1166,9 +1166,6 @@ void set_field_ptr(Field **ptr, const uc
void set_key_field_ptr(KEY *key_info, const uchar *new_buf,
const uchar *old_buf);
-void include_partition_fields_in_used_fields(Field **ptr,
- MY_BITMAP *read_set);
-
bool mysql_backup_table(THD* thd, TABLE_LIST* table_list);
bool mysql_restore_table(THD* thd, TABLE_LIST* table_list);
=== modified file 'sql/sql_partition.cc'
--- a/sql/sql_partition.cc 2010-09-01 08:31:38 +0000
+++ b/sql/sql_partition.cc 2010-09-01 08:44:41 +0000
@@ -7260,31 +7260,5 @@ void create_subpartition_name(char *out,
strxmov(out, in1, "#P#", transl_part_name,
"#SP#", transl_subpart_name, "#REN#", NullS);
}
-/*
- Set fields in partition functions in read set for underlying handlers
-
- SYNOPSIS
- include_partition_fields_in_used_fields()
-
- RETURN VALUE
- NONE
-
- DESCRIPTION
- Some handlers only read fields as specified by the bitmap for the
- read set. For partitioned handlers we always require that the
- fields of the partition functions are read such that we can
- calculate the partition id to place updated and deleted records.
-*/
-
-void include_partition_fields_in_used_fields(Field **ptr, MY_BITMAP *read_set)
-{
- DBUG_ENTER("include_partition_fields_in_used_fields");
- do
- {
- bitmap_set_bit(read_set, (*ptr)->field_index);
- } while (*(++ptr));
- DBUG_VOID_RETURN;
-}
-
#endif
Attachment: [text/bzr-bundle] bzr/magnus.blaudd@sun.com-20100901084441-snds4szd9nf1g4pk.bundle
| Thread |
|---|
| • bzr commit into mysql-5.1-telco-7.0 branch (magnus.blaudd:3741) | Magnus Blåudd | 1 Sep |