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
4e6150d4
Commit
4e6150d4
authored
Mar 01, 2002
by
serg@serg.mysql.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fulltext+const_table bug fixed
parent
87a3c7f0
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
21 additions
and
1 deletion
+21
-1
mysql-test/r/fulltext.result
mysql-test/r/fulltext.result
+6
-0
mysql-test/t/fulltext.test
mysql-test/t/fulltext.test
+10
-0
sql/item_func.cc
sql/item_func.cc
+1
-0
sql/item_func.h
sql/item_func.h
+1
-0
sql/sql_select.cc
sql/sql_select.cc
+2
-1
sql/table.h
sql/table.h
+1
-0
No files found.
mysql-test/r/fulltext.result
View file @
4e6150d4
...
@@ -150,3 +150,9 @@ select * from t1;
...
@@ -150,3 +150,9 @@ select * from t1;
id title
id title
1 this test once revealed a bug
1 this test once revealed a bug
update t1 set title=NULL where id=1;
update t1 set title=NULL where id=1;
drop table t1;
CREATE TABLE t1 (a int(11), b text, FULLTEXT KEY (b)) TYPE=MyISAM;
insert into t1 values (1,"I wonder why the fulltext index doesnt work?");
SELECT * from t1 where MATCH (b) AGAINST ('apples');
a b
drop table t1;
mysql-test/t/fulltext.test
View file @
4e6150d4
...
@@ -129,3 +129,13 @@ check table t1;
...
@@ -129,3 +129,13 @@ check table t1;
update
t1
set
title
=
'this test once revealed a bug'
where
id
=
1
;
update
t1
set
title
=
'this test once revealed a bug'
where
id
=
1
;
select
*
from
t1
;
select
*
from
t1
;
update
t1
set
title
=
NULL
where
id
=
1
;
update
t1
set
title
=
NULL
where
id
=
1
;
drop
table
t1
;
# one more bug - const_table related
CREATE
TABLE
t1
(
a
int
(
11
),
b
text
,
FULLTEXT
KEY
(
b
))
TYPE
=
MyISAM
;
insert
into
t1
values
(
1
,
"I wonder why the fulltext index doesnt work?"
);
SELECT
*
from
t1
where
MATCH
(
b
)
AGAINST
(
'apples'
);
drop
table
t1
;
sql/item_func.cc
View file @
4e6150d4
...
@@ -2108,6 +2108,7 @@ bool Item_func_match::fix_fields(THD *thd,struct st_table_list *tlist)
...
@@ -2108,6 +2108,7 @@ bool Item_func_match::fix_fields(THD *thd,struct st_table_list *tlist)
key
=
NO_SUCH_KEY
;
key
=
NO_SUCH_KEY
;
const_item_cache
=
0
;
const_item_cache
=
0
;
table
=
((
Item_field
*
)
fields
.
head
())
->
field
->
table
;
table
=
((
Item_field
*
)
fields
.
head
())
->
field
->
table
;
table
->
fulltext_searched
=
1
;
record
=
table
->
record
[
0
];
record
=
table
->
record
[
0
];
if
(
key
==
NO_SUCH_KEY
&&
mode
!=
FT_BOOL
)
if
(
key
==
NO_SUCH_KEY
&&
mode
!=
FT_BOOL
)
{
{
...
...
sql/item_func.h
View file @
4e6150d4
...
@@ -930,6 +930,7 @@ public:
...
@@ -930,6 +930,7 @@ public:
ft_handler
=
0
;
ft_handler
=
0
;
if
(
join_key
)
if
(
join_key
)
table
->
file
->
ft_handler
=
0
;
table
->
file
->
ft_handler
=
0
;
table
->
fulltext_searched
=
0
;
}
}
if
(
concat
)
delete
concat
;
if
(
concat
)
delete
concat
;
}
}
...
...
sql/sql_select.cc
View file @
4e6150d4
...
@@ -982,7 +982,8 @@ make_join_statistics(JOIN *join,TABLE_LIST *tables,COND *conds,
...
@@ -982,7 +982,8 @@ make_join_statistics(JOIN *join,TABLE_LIST *tables,COND *conds,
s
->
dependent
=
(
table_map
)
0
;
s
->
dependent
=
(
table_map
)
0
;
s
->
key_dependent
=
(
table_map
)
0
;
s
->
key_dependent
=
(
table_map
)
0
;
if
((
table
->
system
||
table
->
file
->
records
<=
1
)
&&
!
s
->
dependent
&&
if
((
table
->
system
||
table
->
file
->
records
<=
1
)
&&
!
s
->
dependent
&&
!
(
table
->
file
->
option_flag
()
&
HA_NOT_EXACT_COUNT
))
!
(
table
->
file
->
option_flag
()
&
HA_NOT_EXACT_COUNT
)
&&
!
table
->
fulltext_searched
)
{
{
set_position
(
join
,
const_count
++
,
s
,(
KEYUSE
*
)
0
);
set_position
(
join
,
const_count
++
,
s
,(
KEYUSE
*
)
0
);
}
}
...
...
sql/table.h
View file @
4e6150d4
...
@@ -95,6 +95,7 @@ struct st_table {
...
@@ -95,6 +95,7 @@ struct st_table {
my_bool
db_low_byte_first
;
/* Portable row format */
my_bool
db_low_byte_first
;
/* Portable row format */
my_bool
locked_by_flush
;
my_bool
locked_by_flush
;
my_bool
locked_by_name
;
my_bool
locked_by_name
;
my_bool
fulltext_searched
;
my_bool
crashed
;
my_bool
crashed
;
my_bool
is_view
;
my_bool
is_view
;
my_bool
no_keyread
;
my_bool
no_keyread
;
...
...
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