• Type: Icon: Improvement Improvement
    • Resolution: Unresolved
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None

      Being able to project an existing Table or TableView into a new TableView with a different format (i.e. with a different set of columns).

      Transformations:

      • [ ] selection of columns (subset)
      • [ ] rename of columns
      • [ ] remapping (like bringing up value from link)
      • [ ] boolean result of query
      • [ ] result from operations or aggregates on columns
      • [ ] value based on result of query (if query x else y)

      This will need us to support a new kind of TableView that apart from the current row offsets can also contain metadata about column mappings and actual columns of calculated values.

      Suggested syntax:

      // use builder pattern to create new view
      auto view = table.project().column(name) // use columns current name
                                 .column("name_of_boss", boss.name) // remap from link
                                 .column("has_subordinates", subordinates.count() > 0) // result in boolean column
                                 .get_view()
      

            Assignee:
            Unassigned Unassigned
            Reporter:
            alexander.stigsen@mongodb.com Alexander Stigsen (Inactive)
            AD Core
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated: