mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
query expansion for fulltext search
myisam/ft_boolean_search.c: assert.h and queues.h moved to ftdefs.h myisam/ft_parser.c: ft_parse() with alloc myisam/ft_static.c: api changes, ft_max_word_len_for_sort variable removed myisam/ft_update.c: ft_parse() with alloc myisam/ftdefs.h: variable ft_max_word_len_for_sort -> define FT_MAX_WORD_LEN_FOR_SORT api changes, ft_max_word_len_for_sort variable removed ft_parse() with alloc myisam/mi_check.c: variable ft_max_word_len_for_sort -> define FT_MAX_WORD_LEN_FOR_SORT myisam/myisamchk.c: ft_max_word_len_for_sort removed mysql-test/r/fulltext.result: query expansion tests mysql-test/r/fulltext_var.result: ft_max_word_len_for_sort removed mysql-test/t/fulltext.test: query expansion tests sql/ha_myisam.h: ft api changes for query expansion sql/mysqld.cc: ft_max_word_len_for_sort removed ft_query_expansion_limit added sql/set_var.cc: ft_max_word_len_for_sort removed ft_query_expansion_limit added sql/sql_yacc.yy: EXPANSION added to keyword: rule
This commit is contained in:
@ -21,11 +21,15 @@
|
||||
#include "fulltext.h"
|
||||
#include <m_ctype.h>
|
||||
#include <my_tree.h>
|
||||
#include <queues.h>
|
||||
#include <assert.h>
|
||||
|
||||
#define true_word_char(s,X) (my_isalnum(s,X) || (X)=='_')
|
||||
#define misc_word_char(X) ((X)=='\'')
|
||||
#define word_char(s,X) (true_word_char(s,X) || misc_word_char(X))
|
||||
|
||||
#define FT_MAX_WORD_LEN_FOR_SORT 20
|
||||
|
||||
#define COMPILE_STOPWORDS_IN
|
||||
|
||||
/* Interested readers may consult SMART
|
||||
@ -122,13 +126,15 @@ void _mi_ft_segiterator_dummy_init(const byte *, uint, FT_SEG_ITERATOR *);
|
||||
uint _mi_ft_segiterator(FT_SEG_ITERATOR *);
|
||||
|
||||
void ft_parse_init(TREE *, CHARSET_INFO *);
|
||||
int ft_parse(TREE *, byte *, int);
|
||||
int ft_parse(TREE *, byte *, int, my_bool);
|
||||
FT_WORD * ft_linearize(TREE *);
|
||||
FT_WORD * _mi_ft_parserecord(MI_INFO *, uint, const byte *);
|
||||
uint _mi_ft_parse(TREE *parsed, MI_INFO *info, uint keynr, const byte *record);
|
||||
uint _mi_ft_parse(TREE *, MI_INFO *, uint, const byte *, my_bool);
|
||||
|
||||
FT_INFO *ft_init_nlq_search(MI_INFO *, uint, byte *, uint, uint, byte *);
|
||||
FT_INFO *ft_init_boolean_search(MI_INFO *, uint, byte *, uint);
|
||||
|
||||
extern const struct _ft_vft _ft_vft_nlq;
|
||||
FT_INFO *ft_init_nlq_search(MI_INFO *, uint, byte *, uint, uint);
|
||||
int ft_nlq_read_next(FT_INFO *, char *);
|
||||
float ft_nlq_find_relevance(FT_INFO *, byte *, uint);
|
||||
void ft_nlq_close_search(FT_INFO *);
|
||||
@ -137,10 +143,10 @@ my_off_t ft_nlq_get_docid(FT_INFO *);
|
||||
void ft_nlq_reinit_search(FT_INFO *);
|
||||
|
||||
extern const struct _ft_vft _ft_vft_boolean;
|
||||
FT_INFO *ft_init_boolean_search(MI_INFO *, uint, byte *, uint, uint);
|
||||
int ft_boolean_read_next(FT_INFO *, char *);
|
||||
float ft_boolean_find_relevance(FT_INFO *, byte *, uint);
|
||||
void ft_boolean_close_search(FT_INFO *);
|
||||
float ft_boolean_get_relevance(FT_INFO *);
|
||||
my_off_t ft_boolean_get_docid(FT_INFO *);
|
||||
void ft_boolean_reinit_search(FT_INFO *);
|
||||
|
||||
|
Reference in New Issue
Block a user