OHS Open Harvester and URL Based Queries

Open Harvester Systems version 2.3.2.0

Refer to: http://pkp.sfu.ca/wp-content/uploads/2014/04/AdminGuide.pdf page, 14; Topic URL Based Queries

Issue:
OHS allows for URL based queries, it works for searching archive ID with crosswalk ID ‘title’ and ‘author’ but no results if crosswalk ID ‘date’ is queried.

Example URL, this is working:
http://…/byUrl?archive=test1&title=test

also working:
http://…/byUrl?archive=text1&author=retief

What we are not able to get to work, is if we specify date or date ranges of the byUrl query - an example:

http://…/byUrl?archive=tezt1&date=2015

The above example URL; provides no results. We have tried using different format of the date such as 2015-05-20 or 20-07-2015 but the same query results appear; which is none.

We believe this to be bug; but unsure.

Could you provide any guidance in why the crosswalk pubic ID for date is not working in the Url Based Query.

Any assistance would be appreciated - thanks, Trudie

Hi Trudie,

Just browsing the code to remind myself how this works, it looks like you need to specify beginning and end ranges. Try specifying “…&date-from=2015-01-01&date-to=2015-12-31”.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi Alec

Thanks for the guidance, your suggestion could work, however, presently it is not.

Upon further investigation, I could establish that specifying a date range at the normal search tab; doesn’t generate search results. As a result, it seems this OHS version doesn’t generate search results, when a date range is specified.

A similar forum topic was posted, but unfortunately; I could not gain further insight from it. See here: http://pkp.sfu.ca/support/forum/viewtopic.php?f=4&t=1773

Could you guide me, in finding the broken link of the ‘search by date range’ difficulty.

With thanks, Trudie

Hi @tretief,

Can you describe your crosswalk configuration?

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher

The crosswalk configuration is presently ‘Reset To Defaults’.

The date configuration screenshot:

The check boxes enabled:
ETD-MS: Date: A date associated with an event in the life cycle of the resource.
Dublin Core: Date: A date associated with an event in the life cycle of the resource.

Interesting, when I changed the ‘Type’ to Text I was able to search a year, or a date in the search tab without difficulty.

However, the byUrl still didn’t work.

Let me know your thoughts.

Hi @tretief,

The type of the crosswalk should definitely be a date. After changing the type of a crosswalk, you’ll need to re-create your index. If I recall correctly you can do this via the web by flushing and re-harvesting your content, but I’m not 100% sure. The best way to do it is to run the following from the command line:

php tools/rebuildSearchIndex.php

Then try your search again.

Regards,
Alec Smecher
Public Knowledge Project Team

Hi @asmecher

I will flush the metadata, re-harvest and report back (fingers crossed).

Blessings, Trudie