An EQL Ident value has to be a constant I believe? Can it somehow refer to an attribute, dynamic data that is? My case is actually “worse” in that I’d like to OR two attributes to determine the Ident value. I’m guessing that has to be a resolver or it involves multiple queries, but just wanted to confirm it can’t be specified in the query.
idents are more of a legacy feature that still supported, but nowadays is much better to always use the input entity data to provide context data to the query. for instance, instead of:
[{[:user/id 1] [:user/name]}]
you can go with:
{:pathom/entity {:user/id 1} :pathom/eql [:user/name]}
(the later example is supported when you use the boundary interace)
you can also provide more complex entities (many attributes) or even many entities, some examples:
{:pathom/entity {:some-users [{:user/id 1} {:user/id 2}]
:complex-input {:user/first-name "Foo" :user/last-name "bar"}}
:pathom/eql [{:some-users [:user/name]}
{:complex-input [:user/full-name]}]}But still {:user/id 1} cannot be {:user/id :my-specific/id} , as the boundary interface is :root that implies I cannot nest this in a larger query, correct?
not sure if I understand the question, what you mean by boundary interface is :root?
From the https://pathom3.wsscode.com/docs/eql#boundary-interface, it says “Support provision of root entity data”
yes, but you can have complex data on root entity, like on the last example I sent you here
you can make "containers" in the input data with segments, and query inside those
I guess I’m missing something “Foo” and “bar” are constants in your example…
:complex-input {:user/first-name "Foo" :user/last-name "bar"}its an example sending any arbirtrary data, could be ids, or anything else
So then “Foo” can be :my-pathom-attribute/that-can-be-resolved and it’ll sub that value in?
yes
the entity data provides the information you know about, and you can provide anything, them the query you express what you wanna find out, considering that available input