From: Dennis Schafroth Date: Mon, 1 Oct 2012 12:35:47 +0000 (+0200) Subject: Extract and add sorting parameters X-Git-Tag: v4.2.40~8 X-Git-Url: http://lists.indexdata.dk/?a=commitdiff_plain;h=ba9b3f1a1499f53999f7b52f61be79524f5ba26f;p=yaz-moved-to-github.git Extract and add sorting parameters --- diff --git a/src/solr.c b/src/solr.c index 95e0cf1..5863fe1 100644 --- a/src/solr.c +++ b/src/solr.c @@ -413,6 +413,15 @@ int yaz_solr_encode_request(Z_HTTP_Request *hreq, Z_SRW_PDU *srw_pdu, yaz_add_name_value_str(encode, name, value, &i, "fl", request->recordSchema); + switch(srw_pdu->u.request->sort_type) + { + case Z_SRW_sort_type_none: + break; + case Z_SRW_sort_type_sort: + yaz_add_name_value_str(encode, name, value, &i, "sort", + srw_pdu->u.request->sort.sortKeys); + break; + } if (request->facetList) { Z_FacetList *facet_list = request->facetList;