[SERVER-3231] Upsert with $db is failing Created: 09/Jun/11 Updated: 12/Jul/16 Resolved: 12/Dec/13 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Write Ops |
| Affects Version/s: | None |
| Fix Version/s: | 2.5.2 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | John Crenshaw | Assignee: | Scott Hernandez (Inactive) |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||
| Operating System: | ALL | ||||||||||||||||
| Participants: | |||||||||||||||||
| Description |
|
A similar problem was reported a while back as Also, it took me ages to riddle out what was causing this. Is there any way you could give more specific information about the invalid syntax? Something like "okForStorage failed with message: key '$db' is not allowed. Check your record and try again." would have saved an incredible amount of time. "not okForStorage" is just cryptic and unhelpful. |
| Comments |
| Comment by Scott Hernandez (Inactive) [ 12/Dec/13 ] |
|
Please create a new issue and do not re-open this since it has already been committed and released. |
| Comment by Jonathan Abrahams [ 12/Dec/13 ] |
|
// Test that '$id', '$db', and '$ref' are acceptable field names in , { $set: { $id: 1, $db: 1, $ref: 1 }}); ); , { n: 0 }); coll.update( { n: 0 }, { $set: { 'x.$id': 1, 'x.$db': 1, 'x.$ref': 1 }}); ); , { n: 0 }); Assert thrown from second update: 2013-12-12T12:39:01.485-0500 assert failed : gleObj: { |
| Comment by Scott Hernandez (Inactive) [ 27/Jul/13 ] |
|
fixed in |