ArrowDB自定义对象查询两组坐标

时间:2015-10-05 10:14:59

标签: javascript mongodb appcelerator arrowdb

我已经尝试过询问Appcelerator论坛但没有得到回复...希望有人可以在这里提供帮助 - 非常感谢任何帮助。

我正在尝试查询arrowdb自定义对象,以返回两组坐标在5英里范围内的结果

我的自定义对象如下所示:

{
  'name' : 'Text', 
  'coordinates': [
                   [long_1, lat_1], 
                   [long_2, lat_2]
  ]
}

我的查询对象如下所示:

{
    'coordinates': [
        {
            $nearSphere: [ long_1, lat_1 ], 
            $maxDistance: 5/3959
        },
        {
            $nearSphere: [ long_2, lat_2 ], 
            $maxDistance: 5/3959
    ]
}

回应:

{
    code = 500;
    error = 1;
    message = "Internal server error. The Appcelerator Cloud Services Team has just been notified of this problem.";
    success = 0;
}

0 个答案:

没有答案