Skip to content

Named bindings are separate and have no relationship #67

@JackSho

Description

@JackSho

Problem

I use a pattern to filter out such an item from :user/items, this item has a field :store/identity "id2" in :reward/store, when I pull the field item/expired-at of the same level, I got the wrong result, in the following cases, ?expired-at should be 200.

((query '{:user/name  "foo"
          :user/items [{:reward/store    {:store/identity    "id2"
                                          :store/description ?desc}
                        :item/expired-at ?expired-at}]})
 {:user/name  "foo"
  :user/items [{:reward/store    {:store/identity    "id1"
                                  :store/description "description"}
                :item/expired-at 100}
               {:reward/store    {:store/identity    "id2"
                                  :store/description "descriptio2"}
                :item/expired-at 200}]})
;; =>
{?desc "descriptio2"
 &?    #:user{:items [#:item{:expired-at 100}
                      nil]}}

Suggestion

There should be an association between named bindings.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions