The following query
PREFIX dc: <http://purl.org/dc/elements/1.1/>
PREFIX edm: <http://www.europeana.eu/schemas/edm/>
PREFIX ore: <http://www.openarchives.org/ore/terms/>
SELECT *
{
SERVICE <http://sparql.europeana.eu> {
?CHO ore:proxyIn ?proxy;
dc:title ?title ;
dc:creator ?creator ;
dc:date ?date .
FILTER REGEX(str(?creator),"corelli","i").
?proxy edm:isShownBy ?mediaURL .
}
}
computes some titles out of some works of "corelli"
out of the Europeana knowledge base. But when I try to bind a variable ?surname
with a string "corelli"
it returns nothing.
E.g.
SELECT *
{
values ?surname { "corelli" }
SERVICE <http://sparql.europeana.eu> {
?CHO ore:proxyIn ?proxy;
dc:title ?title ;
dc:creator ?creator ;
dc:date ?date .
FILTER REGEX(str(?creator),?surname,"i").
?proxy edm:isShownBy ?mediaURL .
}
}
The FILTER REGEX
expression seems not to work there (I am using a Blazegraph instance to compute this query). Neither if I use str(?surname)
instead of ?surname
.
Why is this so?
Anyone knows what can be done in order to set ?surname with some string values (I might want to gather from another endpoint) and let the query find data ?