From 6b691276c00f607a32c2bbdafe96679788b23ea8 Mon Sep 17 00:00:00 2001 From: Heikki Levanto Date: Mon, 4 May 2015 11:56:52 +0200 Subject: [PATCH] Towards LOC-6: Title indexes for works --- bibframe/triplestore.xml | 58 +++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 52 insertions(+), 6 deletions(-) diff --git a/bibframe/triplestore.xml b/bibframe/triplestore.xml index 5904c59..c48f6c8 100644 --- a/bibframe/triplestore.xml +++ b/bibframe/triplestore.xml @@ -3,7 +3,7 @@ - + rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns bf: http://bibframe.org/vocab/ -
SELECT DISTINCT ?work -
+
SELECT DISTINCT ?work
?work a bf:Work - - ?work bf:workTitle ?wt . - ?wt bf:titleValue %v FILTER(contains(%v, %s)) + + + ?work a bf:Work FILTER( ?work = %u ) + + + + ?work bf:workTitle ?wt . + ?wt bf:titleValue %v FILTER(contains(%v, %s)) + + + ?work bf:workTitle ?wt . + ?wt bf:subtitle %v FILTER(contains(%v, %s)) + + + + ?work bf:workTitle ?wt . + ?wt bf:partTitle %v FILTER(contains(%v, %s)) + + + + + ?work bf:titleVariation ?tv . + ?tv bf:titleValue %v FILTER(contains(%v, %s)) + + + + + ?inst bf:instanceOf ?work . + ?inst bf:instanceTitle ?it . + ?it bf:titleValue %v FILTER(contains(%v, %s)) + + + + + { ?work bf:workTitle ?wt . + { ?wt bf:titleValue %v FILTER(contains(%v, %s)) } UNION + { ?wt bf:subtitle %v FILTER(contains(%v, %s)) } UNION + { ?wt bf:partTitle %v FILTER(contains(%v, %s)) } + } UNION { + ?work bf:titleVariation ?tv . + ?tv bf:titleValue %v FILTER(contains(%v, %s)) + } UNION { + ?inst bf:instanceOf ?work . + ?inst bf:instanceTitle ?it . + ?it bf:titleValue %v FILTER(contains(%v, %s)) + } + + ?work bf:creator ?c . ?c bf:label %v FILTER(contains(%v, %s)) ?work bf:subject ?subject . ?subject bf:label %v FILTER(contains(%v, %s)) + CONSTRUCT { ?work ?rel ?subj } WHERE { -- 1.7.10.4