同步操作将从 nwsuafzq/MySQLAdvisor 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
/* Copyright (c) 2010, 2012, Oracle and/or its affiliates. All rights reserved.This program is free software; you can redistribute it and/or modifyit under the terms of the GNU General Public License as published bythe Free Software Foundation; version 2 of the License.This program is distributed in the hope that it will be useful,but WITHOUT ANY WARRANTY; without even the implied warranty ofMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See theGNU General Public License for more details.You should have received a copy of the GNU General Public Licensealong with this program; if not, write to the Free SoftwareFoundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */#include "sql_parse.h" // check_access#include "sql_table.h" // mysql_alter_table,// mysql_exchange_partition#include "sql_base.h" // open_temporary_tables#include "sql_alter.h"Alter_info::Alter_info(const Alter_info &rhs, MEM_ROOT *mem_root):drop_list(rhs.drop_list, mem_root),alter_list(rhs.alter_list, mem_root),key_list(rhs.key_list, mem_root),create_list(rhs.create_list, mem_root),delayed_key_list(rhs.delayed_key_list, mem_root),delayed_key_info(rhs.delayed_key_info),delayed_key_count(rhs.delayed_key_count),flags(rhs.flags),keys_onoff(rhs.keys_onoff),partition_names(rhs.partition_names, mem_root),num_parts(rhs.num_parts),requested_algorithm(rhs.requested_algorithm),requested_lock(rhs.requested_lock){/*Make deep copies of used objects.This is not a fully deep copy - clone() implementationsof Alter_drop, Alter_column, Key, foreign_key, Key_part_specdo not copy string constants. At the same length the onlyreason we make a copy currently is that ALTER/CREATE TABLEcode changes input Alter_info definitions, but stringconstants never change.*/list_copy_and_replace_each_value(drop_list, mem_root);list_copy_and_replace_each_value(alter_list, mem_root);list_copy_and_replace_each_value(key_list, mem_root);list_copy_and_replace_each_value(create_list, mem_root);list_copy_and_replace_each_value(delayed_key_list, mem_root);/* partition_names are not deeply copied currently */}bool Alter_info::set_requested_algorithm(const LEX_STRING *str){// To avoid adding new keywords to the grammar, we match strings here.if (!my_strcasecmp(system_charset_info, str->str, "INPLACE"))requested_algorithm= ALTER_TABLE_ALGORITHM_INPLACE;else if (!my_strcasecmp(system_charset_info, str->str, "COPY"))requested_algorithm= ALTER_TABLE_ALGORITHM_COPY;else if (!my_strcasecmp(system_charset_info, str->str, "DEFAULT"))requested_algorithm= ALTER_TABLE_ALGORITHM_DEFAULT;elsereturn true;return false;}bool Alter_info::set_requested_lock(const LEX_STRING *str){// To avoid adding new keywords to the grammar, we match strings here.if (!my_strcasecmp(system_charset_info, str->str, "NONE"))requested_lock= ALTER_TABLE_LOCK_NONE;else if (!my_strcasecmp(system_charset_info, str->str, "SHARED"))requested_lock= ALTER_TABLE_LOCK_SHARED;else if (!my_strcasecmp(system_charset_info, str->str, "EXCLUSIVE"))requested_lock= ALTER_TABLE_LOCK_EXCLUSIVE;else if (!my_strcasecmp(system_charset_info, str->str, "DEFAULT"))requested_lock= ALTER_TABLE_LOCK_DEFAULT;elsereturn true;return false;}
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。