Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
47f354bc
Commit
47f354bc
authored
Feb 04, 2005
by
serg@serg.mylan
Browse files
Options
Browse Files
Download
Plain Diff
Merge serg@bk-internal.mysql.com:/home/bk/mysql-4.1/
into serg.mylan:/usr/home/serg/Abk/mysql-4.1
parents
b0bf1950
cc1ee647
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
19 additions
and
16 deletions
+19
-16
include/ft_global.h
include/ft_global.h
+1
-1
myisam/ft_boolean_search.c
myisam/ft_boolean_search.c
+4
-3
myisam/ft_static.c
myisam/ft_static.c
+3
-2
myisam/ftdefs.h
myisam/ftdefs.h
+1
-1
sql/ha_myisam.h
sql/ha_myisam.h
+6
-2
sql/handler.h
sql/handler.h
+1
-2
sql/item_func.cc
sql/item_func.cc
+3
-5
No files found.
include/ft_global.h
View file @
47f354bc
...
@@ -62,7 +62,7 @@ void ft_free_stopwords(void);
...
@@ -62,7 +62,7 @@ void ft_free_stopwords(void);
#define FT_SORTED 2
#define FT_SORTED 2
#define FT_EXPAND 4
/* query expansion */
#define FT_EXPAND 4
/* query expansion */
FT_INFO
*
ft_init_search
(
uint
,
void
*
,
uint
,
byte
*
,
uint
,
byte
*
);
FT_INFO
*
ft_init_search
(
uint
,
void
*
,
uint
,
byte
*
,
uint
,
CHARSET_INFO
*
,
byte
*
);
my_bool
ft_boolean_check_syntax_string
(
const
byte
*
);
my_bool
ft_boolean_check_syntax_string
(
const
byte
*
);
#ifdef __cplusplus
#ifdef __cplusplus
...
...
myisam/ft_boolean_search.c
View file @
47f354bc
...
@@ -365,6 +365,7 @@ static void _ftb_init_index_search(FT_INFO *ftb)
...
@@ -365,6 +365,7 @@ static void _ftb_init_index_search(FT_INFO *ftb)
reset_tree
(
&
ftb
->
no_dupes
);
reset_tree
(
&
ftb
->
no_dupes
);
}
}
ftbw
->
off
=
0
;
/* in case of reinit */
if
(
_ft2_search
(
ftb
,
ftbw
,
1
))
if
(
_ft2_search
(
ftb
,
ftbw
,
1
))
return
;
return
;
}
}
...
@@ -373,7 +374,7 @@ static void _ftb_init_index_search(FT_INFO *ftb)
...
@@ -373,7 +374,7 @@ static void _ftb_init_index_search(FT_INFO *ftb)
FT_INFO
*
ft_init_boolean_search
(
MI_INFO
*
info
,
uint
keynr
,
byte
*
query
,
FT_INFO
*
ft_init_boolean_search
(
MI_INFO
*
info
,
uint
keynr
,
byte
*
query
,
uint
query_len
)
uint
query_len
,
CHARSET_INFO
*
cs
)
{
{
FTB
*
ftb
;
FTB
*
ftb
;
FTB_EXPR
*
ftbe
;
FTB_EXPR
*
ftbe
;
...
@@ -385,8 +386,8 @@ FT_INFO * ft_init_boolean_search(MI_INFO *info, uint keynr, byte *query,
...
@@ -385,8 +386,8 @@ FT_INFO * ft_init_boolean_search(MI_INFO *info, uint keynr, byte *query,
ftb
->
state
=
UNINITIALIZED
;
ftb
->
state
=
UNINITIALIZED
;
ftb
->
info
=
info
;
ftb
->
info
=
info
;
ftb
->
keynr
=
keynr
;
ftb
->
keynr
=
keynr
;
ftb
->
charset
=
((
keynr
==
NO_SUCH_KEY
)
?
ftb
->
charset
=
cs
;
default_charset_info
:
info
->
s
->
keyinfo
[
keynr
].
seg
->
charset
);
DBUG_ASSERT
(
keynr
==
NO_SUCH_KEY
||
cs
==
info
->
s
->
keyinfo
[
keynr
].
seg
->
charset
);
ftb
->
with_scan
=
0
;
ftb
->
with_scan
=
0
;
ftb
->
lastpos
=
HA_OFFSET_ERROR
;
ftb
->
lastpos
=
HA_OFFSET_ERROR
;
bzero
(
&
ftb
->
no_dupes
,
sizeof
(
TREE
));
bzero
(
&
ftb
->
no_dupes
,
sizeof
(
TREE
));
...
...
myisam/ft_static.c
View file @
47f354bc
...
@@ -55,11 +55,12 @@ const struct _ft_vft _ft_vft_boolean = {
...
@@ -55,11 +55,12 @@ const struct _ft_vft _ft_vft_boolean = {
FT_INFO
*
ft_init_search
(
uint
flags
,
void
*
info
,
uint
keynr
,
FT_INFO
*
ft_init_search
(
uint
flags
,
void
*
info
,
uint
keynr
,
byte
*
query
,
uint
query_len
,
byte
*
record
)
byte
*
query
,
uint
query_len
,
CHARSET_INFO
*
cs
,
byte
*
record
)
{
{
FT_INFO
*
res
;
FT_INFO
*
res
;
if
(
flags
&
FT_BOOL
)
if
(
flags
&
FT_BOOL
)
res
=
ft_init_boolean_search
((
MI_INFO
*
)
info
,
keynr
,
query
,
query_len
);
res
=
ft_init_boolean_search
((
MI_INFO
*
)
info
,
keynr
,
query
,
query_len
,
cs
);
else
else
res
=
ft_init_nlq_search
((
MI_INFO
*
)
info
,
keynr
,
query
,
query_len
,
flags
,
res
=
ft_init_nlq_search
((
MI_INFO
*
)
info
,
keynr
,
query
,
query_len
,
flags
,
record
);
record
);
...
...
myisam/ftdefs.h
View file @
47f354bc
...
@@ -131,7 +131,7 @@ FT_WORD * _mi_ft_parserecord(MI_INFO *, uint, const byte *);
...
@@ -131,7 +131,7 @@ FT_WORD * _mi_ft_parserecord(MI_INFO *, uint, const byte *);
uint
_mi_ft_parse
(
TREE
*
,
MI_INFO
*
,
uint
,
const
byte
*
,
my_bool
);
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_nlq_search
(
MI_INFO
*
,
uint
,
byte
*
,
uint
,
uint
,
byte
*
);
FT_INFO
*
ft_init_boolean_search
(
MI_INFO
*
,
uint
,
byte
*
,
uint
);
FT_INFO
*
ft_init_boolean_search
(
MI_INFO
*
,
uint
,
byte
*
,
uint
,
CHARSET_INFO
*
);
extern
const
struct
_ft_vft
_ft_vft_nlq
;
extern
const
struct
_ft_vft
_ft_vft_nlq
;
int
ft_nlq_read_next
(
FT_INFO
*
,
char
*
);
int
ft_nlq_read_next
(
FT_INFO
*
,
char
*
);
...
...
sql/ha_myisam.h
View file @
47f354bc
...
@@ -88,8 +88,12 @@ class ha_myisam: public handler
...
@@ -88,8 +88,12 @@ class ha_myisam: public handler
ft_handler
->
please
->
reinit_search
(
ft_handler
);
ft_handler
->
please
->
reinit_search
(
ft_handler
);
return
0
;
return
0
;
}
}
FT_INFO
*
ft_init_ext
(
uint
flags
,
uint
inx
,
const
byte
*
key
,
uint
keylen
)
FT_INFO
*
ft_init_ext
(
uint
flags
,
uint
inx
,
String
*
key
)
{
return
ft_init_search
(
flags
,
file
,
inx
,(
byte
*
)
key
,
keylen
,
table
->
record
[
0
]);
}
{
return
ft_init_search
(
flags
,
file
,
inx
,
(
byte
*
)
key
->
ptr
(),
key
->
length
(),
key
->
charset
(),
table
->
record
[
0
]);
}
int
ft_read
(
byte
*
buf
);
int
ft_read
(
byte
*
buf
);
int
rnd_init
(
bool
scan
);
int
rnd_init
(
bool
scan
);
int
rnd_next
(
byte
*
buf
);
int
rnd_next
(
byte
*
buf
);
...
...
sql/handler.h
View file @
47f354bc
...
@@ -373,8 +373,7 @@ public:
...
@@ -373,8 +373,7 @@ public:
int
compare_key
(
key_range
*
range
);
int
compare_key
(
key_range
*
range
);
virtual
int
ft_init
()
{
return
HA_ERR_WRONG_COMMAND
;
}
virtual
int
ft_init
()
{
return
HA_ERR_WRONG_COMMAND
;
}
void
ft_end
()
{
ft_handler
=
NULL
;
}
void
ft_end
()
{
ft_handler
=
NULL
;
}
virtual
FT_INFO
*
ft_init_ext
(
uint
flags
,
uint
inx
,
const
byte
*
key
,
virtual
FT_INFO
*
ft_init_ext
(
uint
flags
,
uint
inx
,
String
*
key
)
uint
keylen
)
{
return
NULL
;
}
{
return
NULL
;
}
virtual
int
ft_read
(
byte
*
buf
)
{
return
HA_ERR_WRONG_COMMAND
;
}
virtual
int
ft_read
(
byte
*
buf
)
{
return
HA_ERR_WRONG_COMMAND
;
}
virtual
int
rnd_next
(
byte
*
buf
)
=
0
;
virtual
int
rnd_next
(
byte
*
buf
)
=
0
;
...
...
sql/item_func.cc
View file @
47f354bc
...
@@ -3043,9 +3043,7 @@ void Item_func_match::init_search(bool no_order)
...
@@ -3043,9 +3043,7 @@ void Item_func_match::init_search(bool no_order)
if
(
join_key
&&
!
no_order
)
if
(
join_key
&&
!
no_order
)
flags
|=
FT_SORTED
;
flags
|=
FT_SORTED
;
ft_handler
=
table
->
file
->
ft_init_ext
(
flags
,
key
,
ft_handler
=
table
->
file
->
ft_init_ext
(
flags
,
key
,
ft_tmp
);
(
byte
*
)
ft_tmp
->
ptr
(),
ft_tmp
->
length
());
if
(
join_key
)
if
(
join_key
)
table
->
file
->
ft_handler
=
ft_handler
;
table
->
file
->
ft_handler
=
ft_handler
;
...
@@ -3087,12 +3085,12 @@ bool Item_func_match::fix_fields(THD *thd, TABLE_LIST *tlist, Item **ref)
...
@@ -3087,12 +3085,12 @@ bool Item_func_match::fix_fields(THD *thd, TABLE_LIST *tlist, Item **ref)
}
}
/*
/*
Check that all columns come from the same table.
Check that all columns come from the same table.
We've already checked that columns in MATCH are fields so
We've already checked that columns in MATCH are fields so
PARAM_TABLE_BIT can only appear from AGAINST argument.
PARAM_TABLE_BIT can only appear from AGAINST argument.
*/
*/
if
((
used_tables_cache
&
~
PARAM_TABLE_BIT
)
!=
item
->
used_tables
())
if
((
used_tables_cache
&
~
PARAM_TABLE_BIT
)
!=
item
->
used_tables
())
key
=
NO_SUCH_KEY
;
key
=
NO_SUCH_KEY
;
if
(
key
==
NO_SUCH_KEY
&&
!
(
flags
&
FT_BOOL
))
if
(
key
==
NO_SUCH_KEY
&&
!
(
flags
&
FT_BOOL
))
{
{
my_error
(
ER_WRONG_ARGUMENTS
,
MYF
(
0
),
"MATCH"
);
my_error
(
ER_WRONG_ARGUMENTS
,
MYF
(
0
),
"MATCH"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment