Opened 15 years ago

Last modified 10 years ago

#364 assigned enhancement

sorting cross collection search results

Reported by: kjdon Owned by: kjdon
Priority: moderate Milestone: Possible 2.88 Release
Component: Greenstone2 Runtime Severity: enhancement
Keywords: Cc:


Currently you only get sorting by rank. Is there anyway we can get sorting in natural order?

Requested by users, here are the emails::

Well here is another sorting question - we have several collections that we want users to cross search. My question is that within the individual collection I was able to "sort" the results alphabetically. But once I select the "cross-collection search" feature, when you do a search in the "all" search mode - the results are not in alpha order. So here lies my problem, is it possible to sort it in alpha order in AND/OR have it group by collection.

i.e. Smith, John - Doe, Jane

Vital Statistics Collection

Smith, John World War I Service Records

Smith, Lance - Doe, Jane Vital Statistics Collection

Smith, Mark Passenger Manifest Collection

Smith, Nancy Passenger Manifest Collection

This is basically what we would like users to see in their search for "Smith".

I have two collections built on Greenstone, both of them have sortmeta configured, so that the results come out in a reverse order, according to the date. Now I want to be able to cross-search from one to the other, but as soon as I check the cross-collection option and relaunch the library, the results don't come out sorted. ¿Can the two options co-exist?

Change History (3)

comment:1 by kjdon, 15 years ago

Cross collection search. If the two collections have sortmeta used to return search results eg in Date order, can we keep using this when cross collection searching? ie turn off the sorting by rank.

I guess it would be hard to merge the two lists of documents as we don't have access to the metadata used when sorting, but maybe we can just turn off the ranking and return the top 20 from each collection?

Or they results could be grouped by collection, then sorted inside the group?

If you use Lucene is it possible to do something better?

Can you do cross coll search with Lucene?

comment:2 by kjdon, 15 years ago

Milestone: Release 2.82Release 2.83

comment:3 by kjdon, 10 years ago

Milestone: Greenstone 2 wishlist2.87 Release
Owner: changed from nobody to kjdon
Status: newassigned

Sept 2013. Diego doing cross collection search with Lucene - get option to sort by Date etc. But cross coll search is always sorting by rank. I guess the lucene docs will have no rank, so will come out in the order they are returned from lucene. Which is what diego is seeing. each collection's results are sorted, but there is no merging of the sorted lists. Can we change this?

Can we somehow add a sort_meta into a ResultDocInfo_t, and have a different Query result set that compares the sort meta rather than the ranking? For a lucene query, with a sort field, we get the results and the metadata, and sort the entire list. But what about for natural order?

If the order is just build order, then I don't think we can sort at all. Just do no sorting, and they'll come out in group sets. - how many to have in each set? if returning 50, do we take eg 25 from each of 2 collections? If the build order is sorted, then can we store the sort meta name, and look up that when sorting the search results? It will be like if for lucene we sorted by Date, but it would be the same for each query.

Would we store globally the sortmeta, eg dc.Date, and then look up dc.Date for each document? Or each document could store the meta value used when sorting happened, gs.sortvalue for example, an dwe always look up that value if we have "no sort" on.

Note: See TracTickets for help on using tickets.