#2888 Search function fails to return all hits

v4.3.0
open
nobody
None
5
2012-03-17
2012-03-17
rgdobie
No

When using the General Search, a record is not returned if the search string is contained in the Last Change field as well as in the Name field.

For example :
I log on as rgdobie
When using Advanced search to search exactly for a surname of Dobie, I get 99 matches
Sorting by the Last Change field shows me that 38 of these have a value and 61 have no value.
When using the general search (with 'Exclude some non-genealogical data' set on) and searching for Dobie I get 61 matches - those records with no value in the Last Change field.

I believe the missing records are excluded because of the dobie found in the Last Change. They should only be excluded if that is the only match. If a legitimate match is found, in say the Name field, these records should be returned.

Regards
Richard Dobie

Discussion

  • ggpauly
    ggpauly
    2012-03-27

    Richard,

    I agree that this is a bug.

    You can modify the behavior by switching $tagfilter to "off" in line 63 of file includes/controllers/search_ctrl.php.

    However, this will result in potentially unwanted search hits on the last change _PGVU tag as well as several other tags.

    There is also the workaround of using advanced search, which is not affected.

    This bug exists in function search_indis of file includes/functions/functions_db.php.

    A fix for this bug will require more study of the function when I have time.

    Thanks for the catch and accurate diagnosis,

    George

     
  • rgdobie
    rgdobie
    2012-03-27

    Thanks, George.
    I look forward to seeing it.