diff options
author | Igor Babaev <igor@askmonty.org> | 2012-12-20 10:58:40 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2012-12-20 10:58:40 -0800 |
commit | ca2cdaad86750509764256ff8086e031b4870b24 (patch) | |
tree | bda13b02b556072c72a247b2c6f13f2ec9722ffe /include | |
parent | 6c3de76ad5cb8683ab8b049e0bbba670115d304a (diff) | |
download | mariadb-git-ca2cdaad86750509764256ff8086e031b4870b24.tar.gz |
The patch for the task mdev-539.
The patch lifts the limitation of the current implementation
of ALTER TABLE that does not allow to build unique/primary
indexes by sort for MyISAM and Aria engines.
Diffstat (limited to 'include')
-rw-r--r-- | include/maria.h | 3 | ||||
-rw-r--r-- | include/my_base.h | 6 | ||||
-rw-r--r-- | include/myisamchk.h | 2 |
3 files changed, 10 insertions, 1 deletions
diff --git a/include/maria.h b/include/maria.h index cb2f92e8a35..cab296246b6 100644 --- a/include/maria.h +++ b/include/maria.h @@ -383,7 +383,8 @@ int maria_recreate_table(HA_CHECK *param, MARIA_HA **org_info, char *filename); int maria_disable_indexes(MARIA_HA *info); int maria_enable_indexes(MARIA_HA *info); int maria_indexes_are_disabled(MARIA_HA *info); -void maria_disable_non_unique_index(MARIA_HA *info, ha_rows rows); +void maria_disable_indexes_for_rebuild(MARIA_HA *info, ha_rows rows, + my_bool all_keys); my_bool maria_test_if_sort_rep(MARIA_HA *info, ha_rows rows, ulonglong key_map, my_bool force); diff --git a/include/my_base.h b/include/my_base.h index b711c8bef13..4cbcb00425b 100644 --- a/include/my_base.h +++ b/include/my_base.h @@ -335,6 +335,12 @@ enum ha_base_keytype { #define HA_CREATE_DELAY_KEY_WRITE 64 #define HA_CREATE_RELIES_ON_SQL_LAYER 128 + +/* Flags used by start_bulk_insert */ + +#define HA_CREATE_UNIQUE_INDEX_BY_SORT 1 + + /* The following flags (OR-ed) are passed to handler::info() method. The method copies misc handler information out of the storage engine diff --git a/include/myisamchk.h b/include/myisamchk.h index 9478936c748..789e95572b3 100644 --- a/include/myisamchk.h +++ b/include/myisamchk.h @@ -63,6 +63,8 @@ #define T_ZEROFILL_KEEP_LSN ((ulonglong) 1L << 33) /** If repair should not bump create_rename_lsn */ #define T_NO_CREATE_RENAME_LSN ((ulonglong) 1L << 33) +#define T_CREATE_UNIQUE_BY_SORT ((ulonglong) 1L << 34) +#define T_SUPPRESS_ERR_HANDLING ((ulonglong) 1L << 35) #define T_REP_ANY (T_REP | T_REP_BY_SORT | T_REP_PARALLEL) |