diff options
author | Mikael Ronstrom <mikael@mysql.com> | 2008-12-20 11:53:27 +0100 |
---|---|---|
committer | Mikael Ronstrom <mikael@mysql.com> | 2008-12-20 11:53:27 +0100 |
commit | 5e9d1e8109d9768b57cba848b6ba20b723ba556d (patch) | |
tree | 56dac4082e41c0fd9eb3edadd8a323f0a151b802 /sql/ha_ndbcluster.cc | |
parent | cc958a18dd9554870edd3b1c6119edf72b661879 (diff) | |
parent | 479bc835f8988a1780c4293c0b2595f93a573a61 (diff) | |
download | mariadb-git-5e9d1e8109d9768b57cba848b6ba20b723ba556d.tar.gz |
Merge dtrace patch with latest performance version
Diffstat (limited to 'sql/ha_ndbcluster.cc')
-rw-r--r-- | sql/ha_ndbcluster.cc | 25 |
1 files changed, 7 insertions, 18 deletions
diff --git a/sql/ha_ndbcluster.cc b/sql/ha_ndbcluster.cc index a1e492d9abc..be7ca278302 100644 --- a/sql/ha_ndbcluster.cc +++ b/sql/ha_ndbcluster.cc @@ -10058,34 +10058,23 @@ bool ha_ndbcluster::check_if_incompatible_data(HA_CREATE_INFO *create_info, if (table_changes != IS_EQUAL_YES) DBUG_RETURN(COMPATIBLE_DATA_NO); - /** - * Changing from/to primary key - * - * This is _not_ correct, but check_if_incompatible_data-interface - * doesnt give more info, so I guess that we can't do any - * online add index if not using primary key - * - * This as mysql will handle a unique not null index as primary - * even wo/ user specifiying it... :-( - * - */ - if ((table_share->primary_key == MAX_KEY && pk) || - (table_share->primary_key != MAX_KEY && !pk) || - (table_share->primary_key == MAX_KEY && !pk && ai)) - { - DBUG_RETURN(COMPATIBLE_DATA_NO); - } - /* Check that auto_increment value was not changed */ if ((create_info->used_fields & HA_CREATE_USED_AUTO) && create_info->auto_increment_value != 0) + { + DBUG_PRINT("info", ("auto_increment value changed")); DBUG_RETURN(COMPATIBLE_DATA_NO); + } /* Check that row format didn't change */ if ((create_info->used_fields & HA_CREATE_USED_AUTO) && get_row_type() != create_info->row_type) + { + DBUG_PRINT("info", ("row format changed")); DBUG_RETURN(COMPATIBLE_DATA_NO); + } + DBUG_PRINT("info", ("new table seems compatible")); DBUG_RETURN(COMPATIBLE_DATA_YES); } |