Assigning values to variables

Hi All,

Is it possible to assign a value to a variable, apart from using
pattern matching? More specifically, for instance is it possible to
assign a literal - say a double returned by a function (custom
function) to a variable, which in turn is returned by the query. For
me it would be useful to have a query like:

PREFIX myfn: <java:com.luke.distance.>
PREFIX ps: <http://luke#>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
SELECT ?printer ?distance
WHERE
{
    ?printer rdf:type ps:InkJetPrinterOperational.
    ?distance = myfn:LatLongDistance("-38.15291", "145.135775",
"-38.152197", "154.135783", "K")
}

which returns the printer individual URI and the distance (a double).


Is anything like this possible?


Thanks,



-- 
Luke Steller
PhD Candidate
Faculty of Information Technology
Monash University
A U S T R A L I A
=============================

Received on Wednesday, 23 August 2006 10:46:38 UTC