- From: Patrick Stickler <patrick.stickler@nokia.com>
- Date: Tue, 25 Jun 2002 14:25:16 +0300
- To: ext Geoff Chappell <geoff@sover.net>, RDF Interest <www-rdf-interest@w3.org>
On 2002-06-25 14:27, "ext Geoff Chappell" <geoff@sover.net> wrote:
>
> ----- Original Message -----
> From: "Patrick Stickler" <patrick.stickler@nokia.com>
> To: "ext Geoff Chappell" <geoff@sover.net>; "RDF Interest"
> <www-rdf-interest@w3.org>
> Sent: Tuesday, June 25, 2002 6:33 AM
> Subject: Re: Datatype question
>
>
>>
>> On 2002-06-25 13:22, "ext Geoff Chappell" <geoff@sover.net> wrote:
>>
>>> ... My only point was that queries with
>>> multiple conditions are more efficient if those conditions have common
>>> bindings - e.g. I'd rather be waiting for my system to process "{?a ?b
> ?c}
>>> and {?c ?d ?e}" than "{?a ?b ?c} and {?d ?e ?f} and
>>> somefunc(?c)=somefunc(?d)".
>>
>> Ideally, we should expect a datatype-capable RDF API to handle these
>> things for us, such that queries are made based on known values
>> rather than their literal denotation in the RDF graph. Such an API
>> would also equate the different local vs. global idioms accordingly,
>> such that
>>
>> Jenny age "010.00" .
>> age rdfs:range xsd:decimal .
>>
>> and
>>
>> Bob age [ xsd:decimal "10" ] .
>>
>> would be comparable as
>>
>> Jenny age ?value .
>> Bob age ?value .
>>
>
> I'd expect that would be the case for those datatypes that are natively
> supported by a particular system. For example you might rules like the
> following to allow such comparisons:
>
> //inline case
> infer {?p ?s ?dv} from {[rdfs:range] ?p [xsd:decimal]} and {?p ?s ?o} and
> ?dv=dec(?o)
>
> //qualified case
> infer {?p ?s ?dv} from {?p ?s ?o} and {[xsd:decimal] ?o ?v} and ?dv=dec(?v)
>
> where dec is a function that returns a canonical decimal typed value given a
> string representation.
>
> This would allow value comparisons without the combinatorial explosion I was
> worried about earlier (so what was my point, exactly? :-)
And the moment you start talking about <, >, etc. you're going to have
to use an RDF-external function anyway, so the benefit that tidy literals
seems to offer is really mostly an illusion in actual practice.
Cheers,
Patrick
--
Patrick Stickler Phone: +358 50 483 9453
Senior Research Scientist Fax: +358 7180 35409
Nokia Research Center Email: patrick.stickler@nokia.com
Received on Tuesday, 25 June 2002 07:20:49 UTC