Re: Searching for URIs vs. resources

Bob,

I don't think that a URI is any more or less a key than a Literal.

They have very similar properties in RDF, the only significant difference is that a Literal can only appear in the object slot, and may have a datatype or language tag.

Regards,
   Steve
 
On 17 Dec 2012, at 03:30, Bob DuCharme wrote:

> OK, that makes sense--a URI is inherently a key, so when indexed is easier to look up, while a given literal value is not necessarily, right?
> 
> And congrats on the WG finishing up!
> 
> Bob
> 
> 
> On 12/16/2012 4:41 PM, Andy Seaborne wrote:
>> 
>> 
>> On 16/12/12 21:24, Bob DuCharme wrote:
>>> Imagine that I have ten million triples, and these are two of them:
>>> 
>>>   <http://w> rdfs:label "my literal" .
>>>   <http://x> <http://y> <http://z> .
>>> 
>>> I got the impression somewhere that this query
>>> 
>>>    SELECT ?s WHERE { ?s <http://y> <http://z> }
>>> 
>>> would run faster than this one:
>>> 
>>>    SELECT ?s WHERE { ?s rdfs:label "my literal" }
>>> 
>>> Is this true, and if so is it because URIs will always be indexed and
>>> literals won't necessarily be?
>> 
>> As far as I know, systems generally index literals - quite important for keys.
>> 
>> Maybe there are many, many 'rdfs:label "my literal"' if it's not a key, which might make a difference, as much because there are more results.
>> 
>>> Or is it all dependent on the
>>> implementation?
>> 
>> Yes.
>> 
>>    Andy
> 
> 

Received on Monday, 17 December 2012 08:36:59 UTC