在mongo控制台上运行查询返回特定的数组对象,但试图在MeteorJS中获取同一查询的控制台结果它返回文档

时间:2016-12-01 11:14:10

标签: mongodb meteor

db.companySettings.find({ ' - 编号': “9uvjCujcjSbbLYi86”},{ 'companyEmployeeCategory':1})

当以上查询在mongo命令提示符上运行时,它返回如下答案

{
   "_id":"9uvjCujcjSbbLYi86",
    "companyEmployeeCategory":[
       "ES",
       "OS",
       "OS",
       "ED"
    ]
}

当我在METEORJS中写相同的查询时,我得到了以下答案

Object
_id
:
"9uvjCujcjSbbLYi86"
companyContactNumber1
:
"9623445566"
companyContactNumber2
:
"9604563322"
companyDepartment
:
Array[2]
companyDesignation
:
Array[2]
companyEmail1
:
"iassureit@gmail.com"
companyEmail2
:
"iassureit123@gmail.com"
companyEmployeeCategory
:
Array[7]
companyLocationsInfo
:
Array[2]
companyName
:
"iAssureIT"
companyWebsite
:
"www.iassureit.com"
facebook
:
"iassureit@facebook.com"
generalSettings
:
Array[1]
industryDomain
:
"IT"
leavePolicy
:
Array[4]
linkedInkey
:
"iassureit@linkedin.com"
publicHolidays
:
Array[2]
twitter
:
"iassureit@twitter.com"
youtube
:
"iassureit@youtube.com"
__proto__
:
Object

0 个答案:

没有答案