【问题标题】:Simulate geoNear or near from mongoDB in MySQL在 MySQL 中从 mongoDB 模拟 geoNear 或 near
【发布时间】:2013-10-20 13:19:07
【问题描述】:

在 mongoDB 中有一个名为 geoNear 的命令,它返回到 DB 中地理空间点存储的距离。另外,当我在 mongoDB 中使用 find 函数时,我可以使用一个近过滤器来返回数据库中处于 maxDistance 范围内的寄存器,例如:

db.collection.find( { localizacion:{ $near: { $geometry: { type: "Point", coordinates: [lng, lat]}}, $maxDistance: 1000}}).

这句话返回 DB 中距离 [lng, lat] 1000 米的寄存器。

那么,MySQL中是否有类似的?

谢谢。

【问题讨论】:

    标签: mysql mongodb


    【解决方案1】:
    猜你喜欢
    • 1970-01-01
    • 2012-11-29
    • 2015-04-23
    • 1970-01-01
    • 2020-08-25
    • 2013-04-29
    • 1970-01-01
    • 2015-09-19
    • 1970-01-01
    相关资源
    最近更新 更多