“文档” 菜单
文档首页
/
MongoDB 阿特拉斯
/ /

餐厅数据集样本

在此页面上

  • 集合
  • sample_restaurants.restaurants
  • sample_restaurants.neighborhoods

sample_restaurants数据库包含两个集合,专门帮助您熟悉 GeoJSON数据。

要了解如何将 Atlas 提供的样本数据加载到集群中,请参阅加载样本数据。

sample_restaurants数据库包含以下集合:

集合名称
说明
餐厅
包含餐厅的详细信息。
包含社区详情。

这个集合包含餐厅的账户详细信息。每个文档都包含餐厅的详细信息,如地址、行政区、评分、名称和所供应的食物种类。

sample_restaurants.restaurants 集合包含以下索引:

名称
指数
说明
_id_
{ "_id": 1 }
_id 字段的主键索引。
{
"address": {
"building": "8825",
"coord": [-73.8803827, 40.7643124],
"street": "Astoria Boulevard",
"zipcode": "11369"
},
"borough": "Queens",
"cuisine": "American",
"grades": [ {
"date": {"$date": "2014-11-15T00:00:00.000Z"},
"grade": "Z",
"score": 38
},
{
"date": {"$date": "2014-05-02T00:00:00.000Z"},
"grade": "A",
"score": 10
},
{
"date": {"$date": "2013-03-02T00:00:00.000Z"},
"grade": "A",
"score": 7
},
{
"date": {"$date": "2012-02-10T00:00:00.000Z"},
"grade": "A",
"score": 13
}],
"name": "Brunos On The Boulevard",
"restaurant_id": "40356151"
}

该集合包含纽约市各个社区的详细信息。每个文档包含社区的名称,以及一个包含社区形状的几何子文档。

这些坐标数组通常与 $geoWithin 操作符配合使用,以查询指定边界内的数据。

sample_restaurants.neighborhoods 集合包含以下索引:

名称
指数
说明
_id_
{ "_id": 1 }
_id 字段的主键索引。
{
"geometry": {
"coordinates": [[
[-73.94193078816193, 40.70072523469547],
[-73.9443878859649, 40.70042452378256],
[-73.94424286147482, 40.69969927964773],
[-73.94409591260093, 40.69897295461309],
[-73.94394947271304, 40.69822127983908],
...
[-73.94193078816193, 40.70072523469547]
]]},
"name":"Bedford"
}
← Mflix
商店 →