EPrints Technical Mailing List Archive
See the EPrints wiki for instructions on how to join this mailing list and related information.
Message: #00929
< Previous (by date) | Next (by date) > | < Previous (in thread) | Next (in thread) > | Messages - Most Recent First | Threads - Most Recent First
[EP-tech] Re: Searching in EP3.2
- To: eprints-tech@ecs.soton.ac.uk
- Subject: [EP-tech] Re: Searching in EP3.2
- From: Ian Stuart <Ian.Stuart@ed.ac.uk>
- Date: Wed, 08 Aug 2012 15:34:57 +0100
On 08/08/12 14:35, Tim Brody wrote:
On Wed, 2012-08-08 at 13:57 +0100, Ian Stuart wrote:On 08/08/12 12:33, Tim Brody wrote:On Wed, 2012-08-08 at 11:14 +0100, Ian Stuart wrote:Confused here.... I'm trying to restrict a search, and it's returning 0 results when it should return 19: $searchexp2->add_field($dsd->get_field("field3"), 'Foo bar');Does that need an EQ ANY?It's a single match on a 7-character string... For example, this could be $searchexp2->add_field($dsd->get_field("creator_institution"), 'University of Southampton'); I would expect this to be a singular, complete, match....Then 'EX' ? Otherwise that may (depending on the field) default to 'EQ ALL' (=University AND =of AND =Southampton ...).
Nope. This is the actual, in-code, add_field $searchexp2->add_field( $dso->get_field( "provenance" ), 'Nature Publishing Group', 'EQ', 'ANY'); If it is in.... I get 0 results, If it is out... I get 19 results.If I look in the code that creates the record, it has 'Nature Publishing Group', and if I look in the actual database, it has "Nature Publishing Group" (sans quotes)
After much experimenting with EQ/EX/IN and ANY/ALL, I find I need $searchexp2->add_field( $dso->get_field( "provenance" ), 'Nature Publishing Group', 'EX', 'ALL'); More documentation (and especially examples!) need on the wiki :D -- Ian Stuart. Developer: ORI, RJ-Broker, and OpenDepot.org Bibliographics and Multimedia Service Delivery team, EDINA, The University of Edinburgh. http://edina.ac.uk/ This email was sent via the University of Edinburgh. The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336.
- References:
- [EP-tech] Searching in EP3.2
- From: Ian Stuart <Ian.Stuart@ed.ac.uk>
- [EP-tech] Re: Searching in EP3.2
- From: Tim Brody <tdb2@ecs.soton.ac.uk>
- [EP-tech] Re: Searching in EP3.2
- From: Ian Stuart <Ian.Stuart@ed.ac.uk>
- [EP-tech] Re: Searching in EP3.2
- From: Tim Brody <tdb2@ecs.soton.ac.uk>
- [EP-tech] Searching in EP3.2
- Prev by Date: [EP-tech] Re: Searching in EP3.2
- Next by Date: [EP-tech] Problem with Xapian search
- Previous by thread: [EP-tech] Re: Searching in EP3.2
- Next by thread: [EP-tech] Problem with Xapian search
- Index(es):