Did yo mean something like
SELECT ?type ?name ?b ?double
WHERE { ?b rdf:type ?type ;
# Get the display name for ?b - your property may vary.
rdfs:label ?name ;
# The property that connect ?b to the double value.
:p ?double .
FILTER (?double < 2.5)}
On 04/05/11 14:59, McGibbney, Lewis John wrote:
Hi Chris,
(typo in second name)
fixed now thanks for pointing this out.
WHERE { ?b rdf:type ?type;
owl:NamedIndividual ?NamedIndividual;
xsd:double ?double .
FILTER (?double< 2.5)}
There's something wrong with how you're thinking of this, but I'm not
sure how best to explain it. There is no statement with property xsd:double
in your data, so the query cannot succeed. Similarly there are no statements
with property owl:NamedIndividual; ditto.
What you've written for the triples is shorthand for
?b rdf:type ?type.
?b owl:NamedIndividual ?NamedIndividual.
?b xsd:double ?double .
OK I understand your point. When I think more about it, I am trying to think
logically about how to construct SPARQL query's but have failed to understand
how the triples are structured. I will focus on getting my head around this
problem, hopefully this will have the knock-on effect of producing cleaner more
logical SPARQL queries.
Your properties -- the middle terms of the triples, eg
section6energydomestic2010:hasMaximumAreaWeightedAverageUvalueForAllElementsOfTheSameTypeWperm²K
(which is a horribly long name to be using) -- don't match any of those.
Yes I know this, I think this is something which I will be dealing with in the
future. Currently the RDF resource was produced from domain specific building
regulations, hence the obscure property names.
Thank you for your solution, this is what I was looking for.
PS ?x ?p ?y queries can be very expensive.
I had a feeling that this would be the case, however from viewing various
threads is it a fair comment to say that this will only be the case when
querying over large datasets or many datasets within a triple store? In
comparison my testdata (ath this stage) consists of 329 triples which are being
read into Fuseki manually without the requirement for a triple store.
Glasgow Caledonian University is a registered Scottish charity, number SC021474
Winner: Times Higher Education’s Widening Participation Initiative of the Year
2009 and Herald Society’s Education Initiative of the Year 2009.
http://www.gcu.ac.uk/newsevents/news/bycategory/theuniversity/1/name,6219,en.html
Winner: Times Higher Education’s Outstanding Support for Early Career
Researchers of the Year 2010, GCU as a lead with Universities Scotland partners.
http://www.gcu.ac.uk/newsevents/news/bycategory/theuniversity/1/name,15691,en.html