Bug 10742

Summary: simple search to z39.50 search keeps index
Product: Koha Reporter: Fridolin Somers <fridolin.somers>
Component: Z39.50 / SRU / OpenSearch ServersAssignee: Fridolin Somers <fridolin.somers>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: minor    
Priority: P5 - low CC: bgkriegel, dcook, gmcharlt, katrin.fischer, m.de.rooy, tomascohen
Version: Main   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: Trivial patch
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Bug Depends on:    
Bug Blocks: 5645    
Attachments: Bug 10742 - simple search to z39.50 search keeps index
Bug 10742 - simple search to z39.50 search keeps index
[PASSED QA] Bug 10742 - simple search to z39.50 search keeps index

Description Fridolin Somers 2013-08-16 13:09:47 UTC
In intranet, when search does not return results, there is a button to perform the same search on Z39.50 servers.
This works well when coming from advanced search.
But when using simple search from header, in the Z39.50 search box "kw,wrdl" is added to the operand in title.
Comment 1 Fridolin Somers 2013-08-16 13:18:25 UTC Comment hidden (obsolete)
Comment 2 David Cook 2013-08-21 09:08:01 UTC Comment hidden (obsolete)
Comment 3 David Cook 2013-08-21 09:10:27 UTC
The only thing I wonder about is whether the contents of the simple search should go into "Title" or "Raw (any)", since "Raw" is more of a "keyword" search. 

I looked a bit at how to make it go into "Raw (any)" instead of "Title" but couldn't get it to work so I guess it would require more poking around.

Perhaps "Title" makes the most sense, as people might be more likely to search for titles using the simple search than anything else?
Comment 4 Fridolin Somers 2013-08-21 09:37:21 UTC
(In reply to David Cook from comment #3)
> Perhaps "Title" makes the most sense, as people might be more likely to
> search for titles using the simple search than anything else?
It makes sense for me.
Comment 5 Katrin Fischer 2013-08-21 20:03:27 UTC
Another reason to keep the title might be that you can probably expect the Z39.50 target to support title search, but probably not all support raw?
Comment 6 David Cook 2013-08-21 23:50:39 UTC
(In reply to Katrin Fischer from comment #5)
> Another reason to keep the title might be that you can probably expect the
> Z39.50 target to support title search, but probably not all support raw?

Mmm, I suppose that's a possibility, although I think the Bib-1 attribute for raw (1016) is fairly ubiquitous. 

I'm not too fussed either way. I just thought it might be worth raising :).
Comment 7 Katrin Fischer 2013-08-25 21:11:28 UTC
Created attachment 20609 [details] [review]
[PASSED QA] Bug 10742 - simple search to z39.50 search keeps index

In intranet, when search does not return results, there is a button to perform the same search on Z39.50 servers.
This works well when coming from advanced search.
But when using simple search from header, in the Z39.50 search box "kw,wrdl" is added to the operand in title.

This patch simply adds kw as default value when the cgi does not have idx parameter.

Test plan :
- In intranet, perform a search from header that does not return any result. For example "afalseword"
- Click on "Z39.50 Search"
=> you get a popup with the searched word in title. For example : Title: afalseword
- Go to advanced search page
- Enter the same word into first input and submit
- Click on "Z39.50 Search"
=> you get a popup with the searched word in title.

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de>
Small change, fixes an annoying problem.
Comment 8 Galen Charlton 2013-09-07 18:31:12 UTC
Pushed to master.  Thanks, Fridolyn!
Comment 9 Tomás Cohen Arazi 2013-10-08 16:16:03 UTC
This patch has been pushed to 3.12.x, will be in 3.12.6.

Thanks Fridolyn!
Comment 10 Bernardo Gonzalez Kriegel 2013-10-13 22:52:49 UTC
Pushed to 3.10.x, will be in 3.10.12