2 messages in com.mysql.lists.bugsFULLTEXT query on a table with one ro...| From | Sent On | Attachments |
|---|---|---|
| Patrick Franchini | 07 Feb 2002 20:41 | |
| Patrick Franchini | 07 Feb 2002 20:41 |
| Subject: | FULLTEXT query on a table with one row doesn't filter incorrect records![]() |
|---|---|
| From: | Patrick Franchini (pfra...@cmmt.ubc.ca) |
| Date: | 02/07/2002 08:41:24 PM |
| List: | com.mysql.lists.bugs |
Description:
Queries on a table with one row and a FULLTEXT index returns that one row no matter what the query is. I have included the queries to reproduce this. If a second row is added, the FULLTEXT index it works fine. This happens on 3.23.47 and 4.0.1. I have looked through the mail archives but found nothing on this.
How-To-Repeat:
mysql> CREATE TABLE pubtemp0 ( -> pmid int(11) default NULL, -> title text, -> FULLTEXT KEY title (title) -> ) TYPE=MyISAM; Query OK, 0 rows affected (0.03 sec)
mysql> insert into pubtemp0 values (1,"I wonder why the fulltext index doesnt work?"); Query OK, 1 row affected (0.00 sec)
mysql> select * from pubtemp0; +------+----------------------------------------------+ | pmid | title | +------+----------------------------------------------+ | 1 | I wonder why the fulltext index doesnt work? | +------+----------------------------------------------+ 1 row in set (0.00 sec)
mysql> SELECT * from pubtemp0 where MATCH (title) AGAINST ('apples'); +------+----------------------------------------------+ | pmid | title | +------+----------------------------------------------+ | 1 | I wonder why the fulltext index doesnt work? | +------+----------------------------------------------+ 1 row in set (0.00 sec)
mysql> insert into pubtemp0 values (2,"What if I add a second row to the fulltext index?"); Query OK, 1 row affected (0.00 sec)
mysql> select * from pubtemp0; +------+---------------------------------------------------+ | pmid | title | +------+---------------------------------------------------+ | 1 | I wonder why the fulltext index doesnt work? | | 2 | What if I add a second row to the fulltext index? | +------+---------------------------------------------------+ 2 rows in set (0.00 sec)
mysql> SELECT * from pubtemp0 where MATCH (title) AGAINST ('apples'); Empty set (0.00 sec)
mysql>
Fix:
none known
Submitter-Id: <submitter ID> Originator: Patrick Franchini Organization: <organization of PR author (multiple lines)> MySQL support: none Synopsis: FULLTEXT query on a table with one row doesnt filter Severity: non-critical Priority: low Category: mysql Class: sw-bug Release: mysql-3.23.47 (Source distribution)
Environment:
<machine, os, target, libraries (multiple lines)> System: SunOS sanger 5.7 Generic_106541-16 sun4u sparc SUNW,Ultra-4 Architecture: sun4
Some paths: /usr/local/bin/perl /usr/local/bin/make /usr/local/bin/gmake /usr/local/bin/gcc /usr/local/bin/cc GCC: Reading specs from /usr/local/lib/gcc-lib/sparc-sun-solaris2.7/2.95.2/specs gcc version 2.95.2 19991024 (release) Compilation info: CC='gcc' CFLAGS='' CXX='c++' CXXFLAGS='' LDFLAGS='' LIBC: -rw-r--r-- 1 bin bin 1707752 May 18 2001 /lib/libc.a lrwxrwxrwx 1 root root 11 Dec 5 2000 /lib/libc.so -> ./libc.so.1 -rwxr-xr-x 1 bin bin 1125056 May 18 2001 /lib/libc.so.1 -rw-r--r-- 1 bin bin 1707752 May 18 2001 /usr/lib/libc.a lrwxrwxrwx 1 root root 11 Dec 5 2000 /usr/lib/libc.so -> ./libc.so.1 -rwxr-xr-x 1 bin bin 1125056 May 18 2001 /usr/lib/libc.so.1 Configure command: ./configure --prefix=/usr/local/database/mysql-3.23.47 --with-innodb
-- Patrick Franchini Centre for Molecular Medicine and Therapeutics Vancouver, BC, CANADA e-mail: pfra...@cmmt.ubc.ca Tel: (604) 875-3867




