Skip to content

Empty Join Queries with pluck-many #10

@adstage-david

Description

@adstage-david

We're encountering a case where we have a query:

(p/pluck-many {:db/id {:dashboard/widgets [:db/id]}} dashboard-ids)

The underlying datomic query doesn't return widgets for a certain dashboard, because there are no widgets - but instead of not returning :dashboard/widgets at all, as we would expect from pull-many, it returns the key mapped to an empty map {}:

(p/pluck-many {:db/id {:dashboard/widgets [:db/id]}} dashboard-ids) ;=> [{:db/id 1, :dashboard/widgets {}}]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions