[SERVER-32949] lookup between local (single)value in every object and foreign (single) value and i got an empty array Created: 29/Jan/18 Updated: 28/Feb/18 Resolved: 05/Feb/18 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | JavaScript |
| Affects Version/s: | 3.6.1 |
| Fix Version/s: | None |
| Type: | Question | Priority: | Major - P3 |
| Reporter: | nithin | Assignee: | Bruce Lucas (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Attachments: |
|
| Participants: |
| Description |
|
db.Tasks.aggregate([ { } ] here i get the empty array of userdetails . , , , { "_id": "5a6ed8829f3a0d31f4cd5b61", "executive_id": "5a6ec822c2eee725f8282b3c", "customer_id": "5a67055d611e836db9078ca3", "task_completed": false, "__v": 0, "userdeatails": [] }] |
| Comments |
| Comment by nithin [ 31/Jan/18 ] | |||||||||||
|
k thank you | |||||||||||
| Comment by Bruce Lucas (Inactive) [ 29/Jan/18 ] | |||||||||||
|
Hi, The empty userdetails array indicates that there are no documents in Userdata with an _id matching that customer_id. To check whether this is correct please execute the following:
If this shows that the result of the $lookup is erroneous then we can investigate further. Thanks, |