diff options
author | unknown <serg@serg.mylan> | 2004-02-16 18:53:00 +0100 |
---|---|---|
committer | unknown <serg@serg.mylan> | 2004-02-16 18:53:00 +0100 |
commit | 5a9ffa300aded1a8e5e3b00ed8334e5588653d6d (patch) | |
tree | 9f50a5286834ba27e3397680e3530b5bb72e2392 /sql/mysqld.cc | |
parent | cb6cd9affef3ea86d71a6f447d28fbaf520be098 (diff) | |
download | mariadb-git-5a9ffa300aded1a8e5e3b00ed8334e5588653d6d.tar.gz |
ft_boolean_syntax made changeable
BitKeeper/deleted/.del-gstream.cc~e7a4fae849aff6c8:
Delete: libmysqld/gstream.cc
BitKeeper/deleted/.del-item_subselect.cc~80564bbdb47e8160:
Delete: libmysqld/item_subselect.cc
BitKeeper/deleted/.del-spatial.cc~604df7172b141762:
Delete: libmysqld/spatial.cc
BitKeeper/deleted/.del-sql_derived.cc~548b125128871c7a:
Delete: libmysqld/sql_derived.cc
BitKeeper/etc/ignore:
Added libmysqld/item_subselect.cc libmysqld/sql_derived.cc to the ignore list
Diffstat (limited to 'sql/mysqld.cc')
-rw-r--r-- | sql/mysqld.cc | 28 |
1 files changed, 21 insertions, 7 deletions
diff --git a/sql/mysqld.cc b/sql/mysqld.cc index 509c18d3dda..24c84657b51 100644 --- a/sql/mysqld.cc +++ b/sql/mysqld.cc @@ -317,7 +317,8 @@ char* log_error_file_ptr= log_error_file; char mysql_real_data_home[FN_REFLEN], language[LIBLEN],reg_ext[FN_EXTLEN], mysql_charsets_dir[FN_REFLEN], max_sort_char,*mysqld_user,*mysqld_chroot, *opt_init_file, - *opt_init_connect, *opt_init_slave; + *opt_init_connect, *opt_init_slave, + opt_ft_boolean_syntax[sizeof(ft_boolean_syntax)]; const char *opt_date_time_formats[3]; @@ -3590,7 +3591,7 @@ enum options_mysqld OPT_BACK_LOG, OPT_BINLOG_CACHE_SIZE, OPT_CONNECT_TIMEOUT, OPT_DELAYED_INSERT_TIMEOUT, OPT_DELAYED_INSERT_LIMIT, OPT_DELAYED_QUEUE_SIZE, - OPT_FLUSH_TIME, OPT_FT_MIN_WORD_LEN, + OPT_FLUSH_TIME, OPT_FT_MIN_WORD_LEN, OPT_FT_BOOLEAN_SYNTAX, OPT_FT_MAX_WORD_LEN, OPT_FT_QUERY_EXPANSION_LIMIT, OPT_FT_STOPWORD_FILE, OPT_INTERACTIVE_TIMEOUT, OPT_JOIN_BUFF_SIZE, OPT_KEY_BUFFER_SIZE, OPT_KEY_CACHE_BLOCK_SIZE, @@ -3903,7 +3904,8 @@ Disable with --skip-bdb (will save memory).", 0, 0, 0, 0}, {"master-password", OPT_MASTER_PASSWORD, "The password the slave thread will authenticate with when connecting to the master. If not set, an empty password is assumed.The value in master.info will take precedence if it can be read.", - 0, 0, 0, GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, + (gptr*)&master_password, (gptr*)&master_password, 0, + GET_STR, REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, {"master-port", OPT_MASTER_PORT, "The port the master is listening on. If not set, the compiled setting of MYSQL_PORT is assumed. If you have not tinkered with configure options, this should be 3306. The value in master.info will take precedence if it can be read.", (gptr*) &master_port, (gptr*) &master_port, 0, GET_UINT, REQUIRED_ARG, @@ -4238,6 +4240,10 @@ replicating a LOAD DATA INFILE command.", "A dedicated thread is created to flush all tables at the given interval.", (gptr*) &flush_time, (gptr*) &flush_time, 0, GET_ULONG, REQUIRED_ARG, FLUSH_TIME, 0, LONG_TIMEOUT, 0, 1, 0}, + { "ft_boolean_syntax", OPT_FT_BOOLEAN_SYNTAX, + "List of operators for MATCH ... AGAINST ( ... IN BOOLEAN MODE)", + 0, 0, 0, GET_STR, + REQUIRED_ARG, 0, 0, 0, 0, 0, 0}, { "ft_min_word_len", OPT_FT_MIN_WORD_LEN, "The minimum length of the word to be included in a FULLTEXT index. Note: FULLTEXT indexes must be rebuilt after changing this variable.", (gptr*) &ft_min_word_len, (gptr*) &ft_min_word_len, 0, GET_ULONG, @@ -5415,8 +5421,8 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)), break; case OPT_STORAGE_ENGINE: { - if ((enum db_type)((global_system_variables.table_type= - ha_resolve_by_name(argument, strlen(argument)))) == DB_TYPE_UNKNOWN) + if ((enum db_type)((global_system_variables.table_type= + ha_resolve_by_name(argument, strlen(argument)))) == DB_TYPE_UNKNOWN) { fprintf(stderr,"Unknown table type: %s\n",argument); exit(1); @@ -5581,8 +5587,13 @@ get_one_option(int optid, const struct my_option *opt __attribute__((unused)), global_system_variables.sql_mode= fix_sql_mode(global_system_variables. sql_mode); } - case OPT_MASTER_PASSWORD: - master_password=argument; + case OPT_FT_BOOLEAN_SYNTAX: + if (ft_boolean_check_syntax_string(argument)) + { + fprintf(stderr, "Invalid ft-boolean-syntax string: %s\n", argument); + exit(1); + } + strnmov(opt_ft_boolean_syntax, argument, sizeof(ft_boolean_syntax)); break; case OPT_SKIP_SAFEMALLOC: #ifdef SAFEMALLOC @@ -5628,6 +5639,7 @@ static void get_options(int argc,char **argv) int ho_error; my_getopt_register_get_addr(mysql_getopt_value); + strnmov(opt_ft_boolean_syntax, ft_boolean_syntax, sizeof(ft_boolean_syntax)); if ((ho_error=handle_options(&argc, &argv, my_long_options, get_one_option))) exit(ho_error); if (argc > 0) @@ -5683,6 +5695,8 @@ static void get_options(int argc,char **argv) table_alias_charset= (lower_case_table_names ? files_charset_info : &my_charset_bin); + strnmov(ft_boolean_syntax, opt_ft_boolean_syntax, sizeof(ft_boolean_syntax)); + if (opt_short_log_format) opt_specialflag|= SPECIAL_SHORT_LOG_FORMAT; if (opt_log_queries_not_using_indexes) |