[SERVER-204] mongorestore does not honor -d (--db) flags Created: 30/Jul/09 Updated: 12/Jul/16 Resolved: 15/Sep/09 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Tools |
| Affects Version/s: | 0.9.6, 0.9.7 |
| Fix Version/s: | 1.1.1 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Travis Petticrew | Assignee: | Michael Dirolf |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Environment: |
All |
||
| Participants: |
| Description |
|
mongorestore --help shows that the -d and --db option should set the "database to use." In tools/Tool.cpp this parameter maps to the instance variable _db and this variable is not referenced in tools/restore.cpp. After further digging I see that the target database used is always that of the dumped database and the |
| Comments |
| Comment by Michael Dirolf [ 15/Sep/09 ] |
|
should be available in master / tonight's nightly. if you specify a db (- |
| Comment by Eliot Horowitz (Inactive) [ 11/Sep/09 ] |
|
if there are 2 databases specified, then -d should be illegal and generate an error |
| Comment by Michael Dirolf [ 11/Sep/09 ] |
|
I'm not sure what the expected behavior here is. If I do: What about in the case where I do the default, which is: What should mongorestore -d "baz" do? |