Hello Noel,
I think you can find more information on the computation of the upper hull 
values in [FFS00] "Implementing Geospatial Operations in an Object-Relational 
Database System".
For testing, we used oracle, where we had transient tables.
I am not sure whether we have transient memory tables in SQLite. If yes, you 
can use them.
 
The simple box elimination always goes along with a full table scan. Assume you 
have the polygons of complete Europe in your database and you do a selective 
spatial query, you still have to evaluate all bounding boxes of all polygons. 
In that case a hierarchical organization of the data, e.g. by the Relational 
Quadtree or the Relational R-tree, is certainly much more efficient. If you 
always select let's say more than 10% of all polygons, then the box filtering 
might be enough.
Best Martin
 


----- Ursprüngliche Mail ----
Von: Noel Frankinet <[EMAIL PROTECTED]>
An: sqlite-users@sqlite.org
Gesendet: Freitag, den 19. Mai 2006, 09:38:13 Uhr
Betreff: Re: AW: [sqlite] Re: spatial sqlite anyone ?


Martin Pfeifle wrote:

>Hi,
>I think the simplest solution would be to put a spatial index on top of the 
>B-tree, that's what e.g. Oracle does in their Spatial Cartridge.
>Basically you store the index data in relations and index these relations by 
>B-trees.
>In this case, you do not have to change the core code of SQLite. You can 
>already do this now.
>Nevertheless, it would be nice, if SQlite supports somehow the "extensible 
>indexing interface".
>So, you ask a spatial query and in the background the system uses the index 
>data stored in relations.
>We have done a lot of research on that topic. To get acquainted to the basic 
>idea, you might have a look at
>"The Paradigm of Relational Indexing: A Survey".
> 
>In my opinion, a direct integration of a spatial index is of course 
>preferable, but who is going to do that?
> 
>Best Martin
>
>  
>
Hello Martin, hello All,

Thank you for the above link, it is very useful.
I definitely want to go the spatial index map to btree index way.
I especially like the quad-tree select because I understand it and I 
already have most of the building blocks :
SELECT DISTINCT idx.id
FROM polygons_quadtree idx,
           TABLE(ZDecompose(BOX()) titles,
          Table(ZupperHull(tiles.zval)) uh
WHERE (idx.zval BETWEEN tiles.zval AND ZHi(tiles.zval))
         OR (idx.zval = uh.zval);
Well almost, I know how to make ZDecompose, I still not sure about ZHi, 
ZUpperHul, do you have any more pointers ?

I didn't konw the TABLE statement to return a pseudo table, 
unfortunately, it seems not available in sqlite, can it be emulated by a 
transient memory table ?
Do you think that such a complex statement has any chance to be speedier 
than a simple bbox elimination ?


Thanks again,
Best regards


-- 
Noël Frankinet
Gistek Software SA
http://www.gistek.net

Reply via email to