From 976673f503a49ec953e94bf74f2200a0136db5da Mon Sep 17 00:00:00 2001 From: esikkala <esko.ikkala@aalto.fi> Date: Wed, 22 May 2019 14:05:01 +0300 Subject: [PATCH] Make order by predicate optional --- src/server/sparql/SparqlQueriesGeneral.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/sparql/SparqlQueriesGeneral.js b/src/server/sparql/SparqlQueriesGeneral.js index 43e42bbb..ed67c87d 100644 --- a/src/server/sparql/SparqlQueriesGeneral.js +++ b/src/server/sparql/SparqlQueriesGeneral.js @@ -36,7 +36,7 @@ export const facetResultSetQuery = ` SELECT DISTINCT ?id { <FILTER> ?id a <RDF_TYPE> . - ?id <ORDER_BY_PREDICATE> ?orderBy . + OPTIONAL { ?id <ORDER_BY_PREDICATE> ?orderBy } } ORDER BY (!BOUND(?orderBy)) <SORT_DIRECTION>(?orderBy) <PAGE> -- GitLab