geonames icon indicating copy to clipboard operation
geonames copied to clipboard

Design thoughts on implementing spatial indexes

Open Morgon opened this issue 10 years ago • 3 comments

Using spatial functions would be a pretty huge win for MySQL users in this library.

Of course, there are a number of ways one could go about this, and since it's not my project, I thought I'd start some discussion on the best way to approach it.

When I took a crack at implementing a GeoNames database before finding this project, I simply added an additional POINT column in the main names table, and adding the SPATIAL INDEX. This of course requires the table be MyISAM [and be using MySQL], but I don't think that's a big deal - I doubt anyone will need transactional support on these tables, and I finally figured out how to get the current DB Driver in Laravel :)

In any case, could I follow that same convention to add it to the main table, or would you prefer it be external - either in a separately managed table, or completely out of scope of this module? It'll be trickier to do it this way, but I suppose it could ensure that the main tables were consistent, regardless of driver or settings.

Morgon avatar May 10 '14 08:05 Morgon

Any thoughts here?

Morgon avatar Jun 10 '14 17:06 Morgon

I'll review it tomorrow morning, sorry for the delay @Morgon! Thanks in advance

ipalaus avatar Jun 10 '14 22:06 ipalaus

Sorry about this @Morgon, can you ping me on IRC anytime today or tomorrow?

ipalaus avatar Jul 31 '14 14:07 ipalaus