GraphQL filter in data hub

Hi,

I’m using the data hub function with GraphQL to fetch data for external systems, but I have problems with filters for nested objects.

Taking the example of docs, in the products endpoint of the demo, I make this call and I get all cars called E-Type.

{
getCarListing(filter: “{“name” : “E-Type”}”){
edges{
node{
name
manufacturer{
… on object_Manufacturer{
name
}
}
}
}
}
}

How can I filter on manufacturer name? I was thinking to this filter:
filter : “{“manufacturer” : {“name” : “Jaguar”}}”, but this still filter on car name and not on manufacturer name.

Another question: How is possible make an and condition filter? For exaple for name and color parameters?

Thanks for support,
Dave

2 Likes

Hello, did you find any solution for this question? I am also having same issue

1 Like

Hello,

did you solve this issue? we have the same problem

any solution?

Thank you

1 Like

Hi.

To use multiple filters you must use the comma between one filter and another.

Example: filter:"{“name”:“Jaguar”,“lastname”:“Tiger”}".

Luca.