[MSEARCH-447] Inventory search | Title search | Support strings containing “and” or “&” Created: 18/Sep/20  Updated: 30/Aug/23

Status: Draft
Project: mod-search
Components: None
Affects versions: None
Fix versions: None

Type: Story Priority: P3
Reporter: Charlotte Whitt Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: back-end, backend, elastic-search, epam-spitfire, search, search_enhancements
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original estimate: Not Specified

Attachments: PNG File Skärmavbild 2022-11-21 kl. 3.24.59 em.png     PNG File Skärmavbild 2022-11-21 kl. 3.25.40 em.png     PNG File Skärmavbild 2022-11-21 kl. 3.26.00 em.png     PNG File Skärmavbild 2022-11-21 kl. 3.27.21 em.png     PNG File image (40).png    
Issue links:
Defines
defines UXPROD-3946 Inventory Elastic Search (Poppy): Tim... Open
Relates
relates to MSEARCH-463 Inventory search on Title (all) retur... Closed
relates to UXPROD-4447 Add Inventory search option for Index... Draft
Sprint:
Story Points: 5
Development Team: Spitfire
Release: Not Scheduled
Affected Institution:
!!!ALL!!!
Tester Assignee: Charlotte Whitt

 Description   

Overview: Requirement raised by MSU: Support searching in inventory with strings containing “and” or “&” and getting results that contain the other (eg. “Propaganda and Misinformation” vs. “Propaganda & Misinformation”)

Given two records with following titles:
Instance 1 title == "Propaganda and Misinformation"
Instance 2 title == "Propaganda & Misinformation"

Stories:

  1. Story
    • Login to FOLIO Snapshot, https://folio-snapshot.dev.folio.org/ as diku_admin
    • Go to Inventory app and select the Instance segment
    • Select the title search option
    • When searching: 'Propaganda and Misinformation'
    • Then you get both titles:
      • Instance 1 title == "Propaganda and Misinformation"
      • Instance 2 title == "Propaganda & Misinformation"
  2. Story
    • Clear all searching, and then again select the title search option
    • When searching: 'Propaganda & Misinformation'
    • Then you get both titles:
      • Instance 1 title == "Propaganda and Misinformation"
      • Instance 2 title == "Propaganda & Misinformation"

Test in MG bf environment:
Test setup:

  1. Instance with title Build & construct LAMA
  2. Instance with title Build and construct LAMA

And here the searches, their result and my expectations:

Index Search terms Actual results Expected results
Title (all) build construct lama Instance 1 + 2 Instance 1 + 2
Title (all) build and construct lama Instance 2 Instance 1 + 2
Title (all) build & construct lama No result Instance 1 + 2


 Comments   
Comment by Julian Ladisch [ 21/Sep/20 ]

Should & match "and" in non-English languages, for example the French title "Faune de l'atoll d'And"?
Should & match "und" in German titles, and "et" in French titles, etc.?
Can this feature been disabled per tenant or per query?

Comment by Charlotte Whitt [ 21/Sep/20 ]

Hi Julian Ladisch - thanks, those are great questions. Let me get the SME's feed back on that.

CC: Brooks Travis Felix Hemme lew235

Comment by Charlotte Whitt [ 10/Oct/22 ]

Hi Felix Hemme lew235 Raegan Wiechert - this work might be considered implemented already with the use of relevancy ranking coming out of the box with Elastic Search/Open Search.

Can I ask you to test a little, and let me know what you think. Thanks a lot.

Comment by Felix Hemme [ 10/Oct/22 ]

Hi Charlotte Whitt , where should we test? On https://bugfest-mg.int.aws.folio.org/erm/agreements or https://folio-snapshot.dev.folio.org/ ?

Comment by Raegan Wiechert [ 10/Oct/22 ]

For and/& in titles, searching does not seem to care which you use.  For contributors, it does make a difference. For instance, searching on A and E (Firm) vs. A & E (Firm) returns a different number of hits (the search A E (Firm) returns the same number of hits as the search with the ampersand).  However, I'm not sure if this is the expected behavior or not.  (this was done in the MSU tenant, which is on Lotus) (edit- was also able to confirm the above results in MG bugfest)

Comment by lew235 [ 10/Oct/22 ]

I just tested in Lotus (Cornell's current environment) and found that for both keyword and title searches, searching for '&" retrieves both "and" and "&" BUT searching for "and" does not retrieve "&"

 

Will create the same records and test again in MG bugfest

Comment by lew235 [ 10/Oct/22 ]

I just did the same test in MG bugfest, and I'm not getting any results when I search using "&"

see instance hrid mgin00017360005: https://bugfest-mg.int.aws.folio.org/inventory/view/5d99a657-d7ff-4710-8069-0ad70186c510?qindex=hrid&query=mgin00017360005&sort=title

 

Comment by Felix Hemme [ 12/Oct/22 ]

I can confirm Laura's finding on Bugfest Morning Glory. Here is my test setup:

  1. Instance with title Build & construct LAMA
  2. Instance with title Build and construct LAMA

And here the searches, their result and my expectations:

Index Search terms Actual results Expected results
Keyword
Title (all)
build construct lama Instance 1 + 2 Instance 1 + 2
Keyword
Title (all)
build and construct lama Instance 2 Instance 1 + 2
Keyword
Title (all)
build & construct lama No result Instance 1 + 2
Comment by Charlotte Whitt [ 12/Oct/22 ]

Khalilah Gambrell - I'll move this ticket to be a MSEARCH ticket, and assign it to Spitfire.

CC: Felix Hemme Raegan Wiechert lew235

Comment by Charlotte Whitt [ 27/Oct/22 ]

Hi Khalilah Gambrell can this work be targeted for the Orchid release?

Comment by Khalilah Gambrell [ 28/Oct/22 ]

Hey Charlotte Whitt. We will try to get to this work but our main focus for Orchid will be wrapping up authority control development. 

Comment by Charlotte Whitt [ 01/Nov/22 ]

Hi Khalilah Gambrell - I understand. Thanks for trying.

Comment by Michelle Suranofsky [ 18/Nov/22 ]

Charlotte Whitt or Khalilah Gambrell  - Did the ampersand title search work in lotus and then not in morning glory?  I ask because in lotus bugfest this search works but not in morning glory:
https://bugfest-lotus.int.aws.folio.org/inventory?qindex=title&query=Cataloging%20%26%20classification%20quarterly&sort=title

https://bugfest-mg.int.aws.folio.org/inventory?qindex=title&query=Cataloging%20%26%20classification%20quarterly&sort=title

works correctly in morning glory with 'and'....

https://bugfest-mg.int.aws.folio.org/inventory/view/137f1c7b-acb2-4aa3-83fa-c33b69d6d452?qindex=title&query=Cataloging%20and%20classification%20quarterly&sort=title

 

thank you!

Comment by Charlotte Whitt [ 21/Nov/22 ]

Michelle Suranofsky - this ticket was original written up when we did search by using postgreSQL.

In Lotus, it looks like it works because there is a Variant Title Cataloging and classification quarterly:

Also I notice, that now in Nolana, then Keyword search on this title with an '&' does not work:

Comment by Jenn Colt [ 06/Jan/23 ]

Encountered this in my work this week. Shouldn't affected institution be all?

Generated at Fri Feb 09 00:25:51 UTC 2024 using Jira 1001.0.0-SNAPSHOT#100246-sha1:7a5c50119eb0633d306e14180817ddef5e80c75d.