1
在mongo集合下面有一个名为'职责'的字段。该字段的值是一个很长的字符串,因为它包含下面示例文档中显示的项目符号值)。是否有存储这个值没有更好的办法。如何在mongo字段中存储项目符号列表或值列表
{ "_id" : ObjectId("551d6f4c40cd93dd6bec7dbf"),
"name" : "xxxx",
"desc" : "xxxxxxxxxxxxxxxx xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"teamsize" : 11,
"location" : "xxxxx",
"startDate" : ISODate("2014-06-01T00:00:00Z"),
"endDate" : ISODate("2015-03-01T00:00:00Z"),
"responsibilities" : "1. xxxxxxx , 2.xxxxxx, 3.xxxxxxxx",
"organisationName" : "xxxxxxxx"
}
你的问题相当不清楚,这个项目列表从哪里来?你有任何mongo系列的样品文件吗? – chridam 2015-04-02 16:43:11
编辑该问题以使其更清楚。在我的情况下,项目符号列表来自一个休息端点。 – trial999 2015-04-02 16:51:37
列表中的元素是什么?字符串?数字?名单? – wdberkeley 2015-04-02 18:31:26