diff options
Diffstat (limited to 'sql/table.cc')
-rw-r--r-- | sql/table.cc | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/sql/table.cc b/sql/table.cc index 0f296a85e58..44d639e27a4 100644 --- a/sql/table.cc +++ b/sql/table.cc @@ -45,6 +45,9 @@ #include "ha_sequence.h" #include "sql_show.h" #include "opt_trace.h" +#ifdef WITH_WSREP +#include "wsrep_schema.h" +#endif /* For MySQL 5.7 virtual fields */ #define MYSQL57_GENERATED_FIELD 128 @@ -264,10 +267,14 @@ TABLE_CATEGORY get_table_category(const LEX_CSTRING *db, DBUG_ASSERT(name != NULL); #ifdef WITH_WSREP - if (my_strcasecmp(system_charset_info, db->str, "mysql") == 0 && - my_strcasecmp(system_charset_info, name->str, "wsrep_streaming_log") == 0) + if (my_strcasecmp(system_charset_info, db->str, WSREP_SCHEMA) == 0) { - return TABLE_CATEGORY_INFORMATION; + if ((my_strcasecmp(system_charset_info, name->str, WSREP_STREAMING_TABLE) == 0 || + my_strcasecmp(system_charset_info, name->str, WSREP_CLUSTER_TABLE) == 0 || + my_strcasecmp(system_charset_info, name->str, WSREP_MEMBERS_TABLE) == 0)) + { + return TABLE_CATEGORY_INFORMATION; + } } #endif /* WITH_WSREP */ if (is_infoschema_db(db)) |