[SERVER-9045] mongoimport doesn't accept dbref Created: 21/Mar/13 Updated: 27/Mar/13 Resolved: 27/Mar/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Shell |
| Affects Version/s: | 2.4.0 |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Joe Aung | Assignee: | Shaun Verch |
| Resolution: | Duplicate | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Operating System: | Linux | ||||||||
| Steps To Reproduce: | create a file called dbref-test.js with the following content.
And type in the following command.
You should see the following exception on mongoimport command
FYI: p.json created by mongoexport contains this data.
|
||||||||
| Participants: | |||||||||
| Description |
|
Since I upgraded my mongodb from 2.2.3 to 2.4, some of my mongo shell script stop working. So I had to roll back. mongoimport command throws "BSON representation of supplied JSON is too large" exception when the input json file contain record with DBRef in it. I've tried with both DBRef('name', 'id') or {'$ref': 'name', '$id': 'id'}. Please see below on how to reproduce the issue. |
| Comments |
| Comment by Joe Aung [ 27/Mar/13 ] |
|
Thanks for looking into this, Shaun. |
| Comment by Shaun Verch [ 27/Mar/13 ] |
|
Hi Joe, The json parser is based on http://docs.mongodb.org/manual/reference/mongodb-extended-json/, and it turns out that these docs are wrong for the dbref type. The ticket you can follow to track this fix is Thanks, |