Cross filtering
Filter query results with related entity fields
Cross-relation filters allows you to filter query results with the related entity fields.
During the example we will use the below schema:
Filter 1-1 relations
Fetch all the featured videos those title contains joy
:
Filter 1-M relations
Fetch all the videos published under Joystream
channel:
Modifiers There are three modifiers can be use for M-1 and M-M relationships.
some: if any of the entities in the relation satify a condition
every: if all of the entities in the relation satify a condition
none: if none of the entities in the relation satify a condition
Fetch if any of the entities in the relation satify a condition Example:
Fetch all channels which have at least one video with a title that contains kid
Fetch if all of the entities in the relation satify a condition Example:
Fetch all channels which have all of their videos publishedBefore_eq: true
:
Fetch if none of the entities in the relation satify a condition
Fetch all channels which have none of their videos publishedBefore_eq: true
:
Last updated