[DOCS-1289] mongo shell DBRef is not documented Created: 22/Mar/13 Updated: 30/Oct/23 Resolved: 27/Jul/16 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | manual |
| Affects Version/s: | None |
| Fix Version/s: | Server_Docs_20231030 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Thomas Rueckstiess | Assignee: | Unassigned |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Participants: | |||||||||
| Days since reply: | 7 years, 29 weeks ago | ||||||||
| Description |
|
http://docs.mongodb.org/manual/applications/database-references/#dbrefs It only mentions that the mongo shell offers a DBRef but there is nothing about usage nor an example. For example, it is unclear whether or not the second parameter in DBRef needs to be surrounded by quotes, or needs to be a proper ObjectId. It seems rather flexible when using it in the shell, i.e DBRef("coll", 1) seems to work, however, the JSON parser code insists that the second field is a quoted string containing 24 characters, see: https://github.com/mongodb/mongo/blob/master/src/mongo/db/json.cpp#L663 |
| Comments |
| Comment by Emily Hall [ 27/Jul/16 ] |
|
Closed by Emily Hall for Housekeeping on 7/27/16. Thank you! |
| Comment by Scott Hernandez (Inactive) [ 22/Mar/13 ] |
|
That is a bug in the parser. |