Project

General

Profile

Actions

bug #5868

open

re-establish support for wildcard at start of query string (includes the query string '*' )

Added by Andreas Kohlbecker almost 8 years ago. Updated over 5 years ago.

Status:
Feedback
Priority:
Highest
Category:
cdmlib
Target version:
Start date:
Due date:
% Done:

50%

Estimated time:
Severity:
major
Found in Version:
Tags:

Description

Norbert wrote:

Eine Frage noch zur * wildcard: warum kann ich jetzt nicht mehr bei der erweiterten Taxon-Search mit nur "*" suchen, aber weiterhin bei der einfachen Taxon-Search, wo es gar keinen Sinn macht?

Bei der erweiterten Taxon-Suche erlaubte früher die Kombination aus "*" + Area, das schnelle Erstellen einer Checkliste; Wegfall dieser Möglichkeit ist deshalb ein echter Verlust!


This regression probably is a regression due to the search framework upgrade.

TODO:

  • find the cause for this regression and re-enable this feature

  • implement tests for the various search modes. Wildcards, phrase, ...

related to #3807


Files

picture426-1.png (18.2 KB) picture426-1.png Andreas Müller, 09/16/2018 02:25 PM

Related issues

Related to EDIT - feature request #7517: Make search parameters like wildcards configurableNewKatja Luther

Actions
Actions #1

Updated by Andreas Müller almost 8 years ago

  • Severity changed from normal to major
Actions #2

Updated by Andreas Kohlbecker almost 8 years ago

  • Subject changed from re-establish support for wildcard at start of query string to re-establish support for wildcard at start of query string (includes the query string '*' )
Actions #3

Updated by Katja Luther about 7 years ago

  • Description updated (diff)
  • Priority changed from New to Highest
Actions #4

Updated by Andreas Kohlbecker almost 6 years ago

  • Private changed from Yes to No
Actions #5

Updated by Andreas Kohlbecker almost 6 years ago

Actions #6

Updated by Andreas Kohlbecker almost 6 years ago

  • Target version changed from Unassigned CDM tickets to Release 5.2
Actions #7

Updated by Andreas Kohlbecker over 5 years ago

  • Target version changed from Release 5.2 to Release 5.3
Actions #8

Updated by Andreas Kohlbecker over 5 years ago

  • Target version changed from Release 5.3 to Release 5.4
Actions #9

Updated by Andreas Kohlbecker over 5 years ago

  • Status changed from New to Resolved
  • % Done changed from 0 to 50
Actions #10

Updated by Andreas Kohlbecker over 5 years ago

  • Target version changed from Release 5.4 to Release 5.3

please review

Actions #11

Updated by Andreas Müller over 5 years ago

  • Assignee changed from Andreas Kohlbecker to Andreas Müller
Actions #12

Updated by Andreas Müller over 5 years ago

I get a warning when searching for Achil* on test.cyprus. This is probably not related to this ticket but mention this here as I do the review. It looks like a "sec" is required, but especially misapplications often do not have a sec.

Actions #13

Updated by Andreas Müller over 5 years ago

Wildcards in the same word seem to work. I tested with "chi*ll" on test.cyprus.

However, "chi*ll*san" to find Achillea santolinoides Lag. and similar taxa did not work. It needs a whitespace like "chi*ll san*". Is this expected behavior, then we should mention it in the search explanation.

Actions #14

Updated by Andreas Müller over 5 years ago

For names with multiple whitespaces it is even more tricky.

wilhelm returns "Achillea santolinoides subsp. wilhelmsii (K. Koch) Greuter"

However, "subsp. *wilhelm" does not return anything. Same with "Achil* * * wilhelm" or "Achil* wilhelm"

Actions #15

Updated by Andreas Müller over 5 years ago

The search seems not to be sorted. This is what I get for "V*"

Vitex
Vitis vinifera L.
Vitis
Vulpia brevis Boiss. & Kotschy
Vulpia
Vulpia ciliata Link
Vulpia fasciculata (Forssk.) Fritsch
Vulpia muralis (Kunth) Nees
Vulpia myuros (L.) C. C. Gmel.
Verbenaceae
Hordeum vulgare L. subsp. vulgare
Viola heldreichiana sensu R. D. Meikle
Vulpia membranacea sensu R. D. Meikle
Aegilops biuncialis Vis. subsp. biuncialis
Lobularia libyca (Viv.) Meisn.
Verbascum geminiflorum Hochst.
Aloe vera (L.) Burm. f.
Moricandia spinosa subsp. maroccana sensu R. Vogt & A. Aparicio
Amaranthus graecizans subsp. silvestris (Vill.) Brenan
Vaccaria hispanica (Mill.) Rauschert
...

Actions #16

Updated by Andreas Müller over 5 years ago

was it like this before. Is the sorting by some kind of percentage?

Actions #17

Updated by Andreas Müller over 5 years ago

The area search has a problem. Searching for "V*" and division1 returns NO result.
Searching for "*".

Searching for "*" and "Cyprus" return 1 1/2 pages (but should return almost the whole list)

Actions #18

Updated by Andreas Müller over 5 years ago

OK, on th enew vesion of the cyprus database it works better. Especially the geo-search works better.

But synonym search does not seem to work.

Searching on "Phyla can*" with division6 and accepted+synonym finds Phyla canescens, but Same search on "Phyla fil*" does not find it's synonym Phyla filiformis (Schrad.) Meikle, but should.

Actions #19

Updated by Andreas Müller over 5 years ago

Andreas Müller wrote:

OK, on th enew vesion of the cyprus database it works better. Especially the geo-search works better.

But synonym search does not seem to work.

Searching on "Phyla can*" with division6 and accepted+synonym finds Phyla canescens, but Same search on "Phyla fil*" does not find it's synonym Phyla filiformis (Schrad.) Meikle, but should.

This seems to happen only with subtree filter switched on. But is maybe related to the fix of this ticket as it was not recognized before. Looks like the current implementation does not return any synonyms if the subtree filter is switched on.

The subtree filter works very similar to the classification filter but uses a termQuery instead of IdQuery:

        if(classification != null){
            finalQueryBuilder.add(taxonBaseQueryFactory.newEntityIdQuery("taxonNodes.classification.id", classification), Occur.MUST);
        }
        if(subtree != null){
            finalQueryBuilder.add(taxonBaseQueryFactory.newTermQuery("taxonNodes.treeIndex", subtree.treeIndexWc(), true), Occur.MUST);
        }

The implementation of the term query has been changed within this ticket.

Actions #20

Updated by Andreas Müller over 5 years ago

The classification filter does NOT have any effect in the webservice (1). But it has in the service(2)!

I tested (1) by changing the uuid in the service => returning same result, but should be empty because the classification does not exist. Also I added a second classification with a taxon name that is in both classification => both taxa were returned, though only 1 is in the filter classificaiton. Looks like the classification is set to null somewhere.
Not testing the return valud of classificationService.find(uuid) is definetely a bug. It should return an error message if classification does not exist. Or at least an empty result.

Then, the reason why it is always null is that the former parameter tree has been renamed to classification(Node)Uuid (cdmlib|bfda0eba8f7 and cdmlib|3b2b43193ee). Therefore it is not effective anymore :-(

I tested (2) by writing a test in TaxonServiceSearchTest. Not yet commited.

With the result of (2) - having an effect - the expected behavior is, that synonyms are not found at all, because the classification filter same as the subtree filter queries "taxonNodes.xxx", but for synonyms there is no such field. The field should be "accTaxon.taxonNodes.xxx" but this is not indexed. Maybe this worke some time ago when synonyms were still synonymRelations and the result was handled with the taxonRelationship index. Currently it can't work.

Actions #21

Updated by Andreas Müller over 5 years ago

I moved synonym search and classification/subtree filters to new ticket #7764 as it is not really related to the topic of this ticket

Actions #22

Updated by Andreas Müller over 5 years ago

  • Assignee changed from Andreas Kohlbecker to Andreas Müller

I will try to write tests for the remaining issues and move them to a new ticket.

Actions

Also available in: Atom PDF