[DOCS-10547] Docs for SERVER-142: Read-only views over collection data. Created: 18/Jul/17 Updated: 02/Oct/17 Resolved: 02/Oct/17 |
|
| Status: | Closed |
| Project: | Documentation |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 3.3.12 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Emily Hall | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Participants: | |||||||||
| Days since reply: | 6 years, 30 weeks, 1 day ago | ||||||||
| Description |
Documentation Request Summary:No documentation summary in engineering ticket Engineering Ticket Description:Issue Status as of Aug 31, 2016 ISSUE SUMMARY
In addition, there's also a mongo shell helper db.createView():
Views are readable via the following commands: For more information views, as well as examples, please see the Read-only Views documentation. Original descriptionSupport for read-only views will consist of providing a mechanism for binding a namespace name to a (namespace name, query) pair, where the query might be a MongoDB query or an aggregation expression. For example, if you had a collection "housing.apartments", you might create a view
Finds on cheapApartments would only consider those elements of housing.apartments where the "rent" field was less than 1000. By using an aggregation expression with an unwind stage, you could produce a view over a database that had one document for every member of an array in an input document, providing another means to examine and query embedded documents. |