Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-4723

Export Collection - Path Collision Error

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Minor - P4 Minor - P4
    • 1.37.0
    • Affects Version/s: 1.26.0, 1.33.1, 1.34.1
    • Component/s: Import/Export
    • None
    • Environment:
      macOS Catalina Version 10.15.7
    • Not Needed

      Problem Description 

      The collection export function of Compass 1.26.0 is faulty. The reason for this is a self-inflicted path collision error (see picture 1). This error occurs when a certain object contains properties (/fields and values) in some documents and is empty in others. For example, the error currently pops up when trying to export the "listingsAndReviews" collection of the airbnb sample record. 

      Should an object contain properties in some documents and none in others, the export function provides an export field for the object in general as well as a field for each object property. In the airbnb case it includes "review_scores" and "review_scores.review_scores_accuracy" etc. (see picture 2). Compass thereby does not comply with the mongoDB Path Collision Restrictions introduced in mongoDB 4.4 (https://docs.mongodb.com/manual/release-notes/4.4-compatibility/#path-collision-restrictions).

      We tested the behavior on two devices operating on Compass version 1.26.0 accessing different clusters. In both cases this error occurred.

      Issue Fix

      On my private mac this issue does not occur. It operates on version 1.24.1.

      Furthermore, you can circumvent this issue by either unticking the object field in the export settings window or by unticking all the individual object properties. In the example above by either unticking "review_scores" or all of review_scores's properties listed in dot notation. In both cases Compass exports all the data.

      Steps to Reproduce

      • Load the sample data set into your cluster
      • Use Compass 1.26.0
      • Try to export "listingsAndReviews" from sample_airbnb (or any other collection where a document object contains properties in some cases and no properties in others)

      Expected Results

      Export of collection into a JSON file.

      Actual Results

      Path Collision Error

      Additional Notes

        1. Screen Shot 2021-03-29 at 2.39.36 PM.png
          Screen Shot 2021-03-29 at 2.39.36 PM.png
          92 kB
        2. Screen Shot 2021-03-29 at 2.02.36 PM.png
          Screen Shot 2021-03-29 at 2.02.36 PM.png
          97 kB
        3. picture 2.png
          picture 2.png
          296 kB
        4. picture 1.png
          picture 1.png
          113 kB

            Assignee:
            Unassigned Unassigned
            Reporter:
            clemens.kunst@mongodb.com Clemens Kunst
            Votes:
            4 Vote for this issue
            Watchers:
            9 Start watching this issue

              Created:
              Updated:
              Resolved: