473,773 Members | 2,315 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

FULLTEXT inconsistency

I have a FULLTEXT index.

when i query it for a specific item, i get different results in
phpMyAdmin, vs a PHP search app I'm developing.

In the PHP search app, the match I expect isn't returned (in fact
nothing is returned), though in phpMyAdmin, the exact match i expect
is returned -

the query i am using to test this is specific enough to isolate the
result to one match.

Here is my query:

SELECT product_id as id, product_name, MATCH(product_i d,
product_name,
notes,
material,
manufacturer,
country)
AGAINST ('+(>$search_te rm*)' IN BOOLEAN MODE)
AS m FROM quick_search WHERE MATCH(product_i d,
product_name,
notes,
material,
manufacturer,
country)
AGAINST ('+(>$search_te rm*)' IN BOOLEAN MODE)
ORDER BY m DESC, product_name ASC
also, in my search app, if i search for something that doesn't exist, i
get tons of bad results - but in phpMyAdmin, i get 0, which is what i'd
like in the search app.

any clues to what's going on here, given the queries are identical?

thanks,
s7

Jan 9 '07 #1
1 2127

st******@hotmai l.com wrote:
I have a FULLTEXT index.

when i query it for a specific item, i get different results in
phpMyAdmin, vs a PHP search app I'm developing.

In the PHP search app, the match I expect isn't returned (in fact
nothing is returned), though in phpMyAdmin, the exact match i expect
is returned -

the query i am using to test this is specific enough to isolate the
result to one match.

Here is my query:

SELECT product_id as id, product_name, MATCH(product_i d,
product_name,
notes,
material,
manufacturer,
country)
AGAINST ('+(>$search_te rm*)' IN BOOLEAN MODE)
AS m FROM quick_search WHERE MATCH(product_i d,
product_name,
notes,
material,
manufacturer,
country)
AGAINST ('+(>$search_te rm*)' IN BOOLEAN MODE)
ORDER BY m DESC, product_name ASC
also, in my search app, if i search for something that doesn't exist, i
get tons of bad results - but in phpMyAdmin, i get 0, which is what i'd
like in the search app.

any clues to what's going on here, given the queries are identical?

thanks,
s7
i fugured out the missing result problem, but not the part about
getting seemingly all the results when there is no match (which doesn't
happen in phpMyAdmin).

the first problem had to do with using an include file that limited the
results. i suppose the second problem is also php/app related.

thanks,
s7

Jan 9 '07 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
4023
by: Phil Powell | last post by:
Relevancy scores are normally defined by a MySQL query on a table that has a fulltext index. The rules for relevancy scoring will exclude certain words due to their being too short (minimum default is 4 letters). This is the Fed. Everything is a TLA (three-letter acronym). Therefore, since I'm building a PORTABLE web application, changing MySQL's default settings for fulltext index querying is completely undoable and unrealistic, so...
0
5771
by: Phil Powell | last post by:
The table already has a fulltext index and from there I can use the MySQL fulltext search query to get results as well as the relevancy score. The problem I have is that MySQL has a default setting whereby the minimum amount of characters is 4 for a search. Being that we're government and full of TLA (three-letter acronyms), that is not practical, and furthermore, the app I'm building must be fully portable, so having MySQL tweaked...
0
510
by: Wesley Hobbie | last post by:
------=_NextPart_000_0000_01C34DF5.B670D500 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit I am running MySQL 4.0.12 on Windows XP. I am trying to create a library database and have a table named "cardCatalog" in the "library" database. The cardCatalog has the following fields: callNumber (varchar(60)), title (varchar(255)), author (varchar(255)), category (varchar(100)), location (varchar(100)),...
0
1768
by: Ralph Guzman | last post by:
I have to do a catalog search through multiple tables and columns for product model number, description, and name. I realize that doing pattern matching with multiple LIKE statements is slow so I found that FULLTEXT searches is a better alternative. I have added a FULLTEXT index to the tables I'm searching, but I get an unkown error when I run my query: SELECT p2c.categories_id, p.products_id, pd.products_name, p.products_quantity,...
0
1286
by: Matt W | last post by:
Hi all, I'm planning to use MySQL's full-text search for my forum system (possibly 5+ million posts). I've been playing with it a lot lately to see the performance and functionality and have some suggestions/questions. First, since a few of you may be wanting to know, here is a thread where I was doing some speed/optimization tests and stuff with 3 million posts: http://www.sitepointforums.com/showthread.php?threadid=69555
0
476
by: Phil Powell | last post by:
Retracing my problem leads me to believe I never successfully created fulltext indexes for MySQL 3.23.58 MyISAM tables. I went to the MySQL manual and was able - or so I thought - to create them, however, my fulltext search queries fail in 3.23.58 but the exact queries (with same data) work perfectly in 4.0.10. --...
0
519
by: Alex Glass | last post by:
I have a large contacts table with about 30 columns of text fields and 5 fulltext indexes spanning the different sections of the table. I'm curious if anyone could suggest a better way to find rows in the table based on text entered by the user. It also would be nice if wildcards could be supported like "beginning*". The query I have built crashed mysqlnt-d a few times but I was unable to determine what triggered the crash. I believe it...
0
1425
by: Robert Oschler | last post by:
I read a while back that MySQL will only use one index per query. (If this is not so, please tell me and point me to a doc that gives a good explanation of MySQL's current index usage policy). I'm using MySQL 4.2.x. Here's my dilemma. 1) --------- I have two tables that have records with a FULLTEXT index text field in each of them. The problem is the relationship between the tables is a
1
2424
by: Robert Oschler | last post by:
I read a while back that MySQL will only use one index per query. (If this is not so, please tell me and point me to a doc that gives a good explanation of MySQL's current index usage policy). I'm using MySQL 4.2.x. Here's my dilemma. 1) --------- I have two tables that have records with a FULLTEXT index text field in each of them. The problem is the relationship between the tables is a
0
9621
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10264
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10106
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10039
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
9914
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
8937
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7463
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5484
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
3
2852
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.