Uploaded image for project: 'Documentation'
  1. Documentation
  2. DOCS-12112

Docs should explicitly state the limitation that views cannot be created on collections present in another database

    XMLWordPrintable

Details

    • Task
    • Status: Resolved
    • Minor - P4
    • Resolution: Fixed
    • None
    • None
    • manual, Server

    Description

       

      Currently, it is not possible to create a view in one database sourced from a collection in another database. As indicated in the db.createView() documentation (https://docs.mongodb.com/v3.6/reference/method/db.createView/#db.createView), the source parameter for the view does not include the database name and implies the same database as the view to create. However this statement is buried deep and is very subtle.

      It would help if the documentation on views and db.createView explicitly state the limitation that it is not possible to create a view in one database sourced from a collection in another database.

       

      Attachments

        Activity

          People

            isabella.siu@mongodb.com Isabella Siu (Inactive)
            harshad.dhavale@mongodb.com Harshad Dhavale
            Isabella Siu Isabella Siu (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              3 years, 43 weeks, 5 days ago