Reputation: 1452
Postgres is the DB of choice due to its spatial indexing goodness (top-k-closest-points) using PostGIS or other gists. Looks like Node.js ORMs do not directly support spatial indexing, so which one requires the least amount of hacking for this? Sequelize and node-orm-2 seem to demand some hacking to get it working. Any suggestions?
Upvotes: 2
Views: 1657
Reputation: 9418
As of sequelize 3.4.0, Geometry support has been added for postgres. You can use the GEOMETRY datatype in the model definition:
sequelize.define("point", {
geom: DataTypes.GEOMETRY
});
Upvotes: 2