lundi 2 mars 2015

Sorting by X/Y location, by nearest item

I got a list of items (450), with X/Y locations on a map, in a SQLite db (looks like this http://ift.tt/1EFiIlr )


the map is flat and looks like this http://ift.tt/18ggv2N


i want to sort this list by the X/Y locations, so the next item is the 1 closest to the previous item.


how can i sort them like this?


(also, would be nice to know, but is not important: can i do this sort in a SQLite query alone?)


Aucun commentaire:

Enregistrer un commentaire