#6934 closed defect (bug) (fixed)

Search not returning obvious matches

Reported by: topher1kenobe's profile topher1kenobe Owned by: otto42's profile Otto42
Milestone: Priority: normal
Component: Photo Directory Keywords:


This search:

does not return this image:

despite the search terms being exactly represented in the alt text.

Change History (4)

#1 @Otto42
12 months ago

This comes from the limit_partial_matching function. I'm not entirely certain what the purpose of this regular expression is, but something about it doesn't look right.

#3 @Otto42
12 months ago

The relevant portion of the SQL:

OR (post_content LIKE 'peanut%') ...
OR (post_content LIKE 'butter%') ...

And so on. Basically, it will only match peanut or butter at the start of the content. Probably not what was intended, so it's unlikely that that fix worked.

#4 @Otto42
12 months ago

  • Owner set to Otto42
  • Resolution set to fixed
  • Status changed from new to closed

In 12543:

Photo directory: Switch limit matching to use a regular expression for the query. The extra backslashes are because of the ridiculous escaping necessary for both PHP and mySQL. Fixes #6934. Related #6569

Note: See TracTickets for help on using tickets.