indexing and ordered searches

What triple stores offer any optimization for integer or other numeric queries, e.g. with the following query

SELECT  ?a
WHERE { ?a  eg:prop ?i .
        FILTER ( 10 < ?i && ?i < 15 ) }

a naive approach would be to find all eg:prop triples and compute the filter for each one (O(N) complexity); if the store only has say integers as objects of eg:prop then a Predicate/Object index could achieve the same result in O(log(N)) by a numeric binary chop on the Object part of the index.

I looked at the TDB code and got the impression that the indices do in fact preserve ordering of at least some types, but could not see FILTERs being treated in the way indicated here … then I thought I would ask here.

Jeremy

Received on Tuesday, 22 January 2013 00:12:16 UTC