Thanks, that worked!

Br,
Mikael


On 14.4.2016 12:36, Martynas Jusevičius wrote:
My guess would be that because of SPARQL bottom-up semantics,
?prefLabel is undefined at the point where you are applying it. Try
moving it out of OPTIONAL.

On Thu, Apr 14, 2016 at 11:11 AM, Mikael Pesonen
<mikael.peso...@lingsoft.fi> wrote:
Hi,

im matching strings in different graphs and this should do the trick:

SELECT ?prefLabel ?s2
WHERE {
   GRAPH <http://www.lingsoft.fi/somegraph>
   {
     ?s skos:prefLabel ?prefLabel .
   }
   OPTIONAL {
     GRAPH ?graph
     {
       ?s2 skos:prefLabel ?label2

       FILTER ( lcase(str(?prefLabel)) = lcase(str(?label2)) )
     }
   }
}

but im not getting any results. There are plenty of matches in store and
this returns them (case sensitive match)

SELECT ?prefLabel ?s2
WHERE {
   GRAPH <http://www.lingsoft.fi/somegraph>
   {
     ?s skos:prefLabel ?prefLabel .
   }
   OPTIONAL {
     GRAPH ?graph
     {
       ?s2 skos:prefLabel ?prefLabel
     }
   }
}


Im I using FILTER wrong way or could it be a bug in search engine?

Br,
Mikael

--
www.lingsoft.fi

Speech Applications - Language Management - Translation - Reader's and
Writer's Tools - Text Tools - E-books and M-books

Mikael Pesonen
System Engineer

e-mail: mikael.peso...@lingsoft.fi
Tel. +358 2 279 3300

Time zone: GMT+2

Helsinki Office
Eteläranta 10
FI-00130 Helsinki
FINLAND

Turku Office
Linnankatu 10 A
FI-20100 Turku
FINLAND


--
www.lingsoft.fi

Speech Applications - Language Management - Translation - Reader's and Writer's 
Tools - Text Tools - E-books and M-books

Mikael Pesonen
System Engineer

e-mail: mikael.peso...@lingsoft.fi
Tel. +358 2 279 3300

Time zone: GMT+2

Helsinki Office
Eteläranta 10
FI-00130 Helsinki
FINLAND

Turku Office
Linnankatu 10 A
FI-20100 Turku
FINLAND

Reply via email to