MySQL Forums
Forum List  »  Full-Text Search

FullText not work for me
Posted by: Huy Ho
Date: October 22, 2007 12:41AM

I am new to fulltext index. And I made my first example as follow:

mysql> use test;
Database changed
mysql> create table test(id int auto_increment primary key, data text, fulltext
index dataIndex(data)) engine=MyISAM;
Query OK, 0 rows affected (0.06 sec)

mysql> insert into test(data) values('this is the first row');
Query OK, 1 row affected (0.00 sec)

mysql> insert into test(data) values('this is the second row');
Query OK, 1 row affected (0.00 sec)

mysql> insert into test(data) values('this is the third row');
Query OK, 1 row affected (0.00 sec)

mysql> insert into test(data) values('i dont know what happen');
Query OK, 1 row affected (0.00 sec)

mysql> insert into test(data) values('please stop cheating me');
Query OK, 1 row affected (0.00 sec)

mysql> insert into test(data) values('thank you for your help');
Query OK, 1 row affected (0.00 sec)

mysql> insert into test(data) values('my first fulltext search example');
Query OK, 1 row affected (0.00 sec)

mysql> select match(data) against('first') from test;
+------------------------------+
| match(data) against('first') |
+------------------------------+
| 0 |
| 0 |
| 0 |
| 0 |
| 0 |
| 0 |
| 0 |
+------------------------------+

I dont know why all result rows are 0. What do i need to make the full text work?

Options: ReplyQuote


Subject
Views
Written By
Posted
FullText not work for me
3785
October 22, 2007 12:41AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.