Hello everyone,
I'm currenty trying to generate a query with jena spatial
(https://jena.apache.org/documentation/query/spatial-query.html)
|PREFIX spatial: <http://jena.apache.org/spatial#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?placeName
{
?place spatial:query(51.46 2.6 10 'km') .
?place rdfs:label?placeName
}|
The example shows a fixed lat/lon to work with. I want to query a
variable position given by some position values (e.g of a person):
|PREFIX spatial: <http://jena.apache.org/spatial#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX geo: <http://www.w3.org/2003/01/geo/wgs84_pos#>
PREFIX person: <http://example.org/person#>
SELECT ?placeName
{
?person geo:lat?lat.
?person geo:long?long.
?place spatial:query(?lat?long10 'km') .
?place rdfs:label?placeName
FILTER(?person= person:testPerson1)
}|
The second statement does not work and is only an indicator to what i mean.
The question is: how can I do that?
Ty., greetings :)