[HN Gopher] The SQLite R*Tree Module
___________________________________________________________________
The SQLite R*Tree Module
Author : sirffuzzylogik
Score : 24 points
Date : 2021-03-10 21:39 UTC (1 hours ago)
(HTM) web link (www.sqlite.org)
(TXT) w3m dump (www.sqlite.org)
| centimeter wrote:
| I love SQLite's software model (embeddable library rather than a
| separate binary), but I often sorely miss the rich data model
| provided by postgres. I miss things like strong type checking,
| special types to represent times/coordinates/etc., and advanced
| index types like GiST indices.
| hagibborim wrote:
| How close does DuckDB get to fulfilling your needs?
| yowlingcat wrote:
| Having used this in production before, it's an absolutely
| fantastic tool for specific use cases. My use case was indexing
| fairly static medium cardinality geo data for lookup within a
| microservice that we hit from our primary monolith. You get fast
| spatial indexes and essentially zero additional operational
| overhead.
| yread wrote:
| Note that even though it's a module lot of distributions of
| Sqlite come with it enabled. You can check it by running
|
| PRAGMA compile_options;
|
| and looking for ENABLE_RTREE
| bob1029 wrote:
| I have started to play around with building a software rasterizer
| from scratch, and I am wondering if this might be something that
| I could potentially leverage to cheat at some of the math
| problems. The document mentions CAD, but I am not sure if the
| performance is such that real-time (i.e. 30+fps) queries would be
| feasible over meaningful datasets.
|
| Does anyone have any experience directly using SQL for this sort
| of thing? I feel like there is something here with being able to
| define a 3d scene in terms of normalized SQL tables, and then
| running queries over them in order to produce intermediate/final
| output.
| jjmod wrote:
| It might be feasible if you use sqlite's in-memory feature,
| because hitting the disk on each query is way too slow for a
| real-time application.
|
| Why not just use an r-tree library for the language you're
| using? It'll be faster and easier to work with. Since scene
| data is usually hierarchial, sql doesn't seem like a great
| choice for storing it
___________________________________________________________________
(page generated 2021-03-10 23:00 UTC)