Deep filtering on both CMA and CDA

And also on the clients, including the Gatsby source plugin.

Hi,

Is there any update on this? It was said to be ready in November here https://github.com/datocms/product-roadmap/issues/98#issuecomment-440204772

Thanks,

Unfortunately we have stopped working on this and it’s currently unplanned.

We hit some roadblocks and we have decided to postpone it. It will very likely happen during 2019, but we don’t have an ETA yet.

:cry:

Just popped in to add some context for the request.

Dynamic Linking example OR Filter by nested property:

We can execute a top-level query for " shoppingCategory " by $path in order to get the category.id

  • (linking) We can’t dynamically pass the category.id into allShoppingArticles query
  • (filter by nested property) We can only filter allShoppingArticles by category.id , but if we could filter by category.fullPath then we wouldn’t need linking
query ShoppingArticlesByCategory($path: String) {
  shoppingCategory(filter: {fullPath: {eq: $path}}) {
    label
    id
    fullPath
  }
 // can't filter by category.fullPath
 // can't dynamically insert $category.id from above query ("5703546" is the resulting category.id)
  allShoppingArticles(filter: {category: {eq: "5703546"}}) {    
    slug
    category {
      label
      fullPath
      id
    }
  }
}

Voting this feature request up if it’s asking for linking or nested-filter support for properties other than “id”.

3 Likes

I would like to be able to query by the slug of a linked field, currently only .id can be used.

allPrefectures(first: 100, filter: {region: {eq: "10101"}}) {
    slug
    name
    position
    region {
      slug
      name
      id
      position
    }
  }

For example, prefectures references region, and the prefectures inside a region are listed in a page /region/[region slug], currently, 2 queries are needed:

  1. region.slug -> lookup and find region.id
  2. fetch all prefectures under that region by allPrefectures(first: 100, filter: {region: {eq: “[region.id]”}})

It would be great if we can query records directly by slugs of linked fields. This kind of lookup should be quite common for hierarchy based listings, like category > articles, tags > articles, main category > sub category > shop item etc.

5 Likes

@matjack1 Will this by any chance be supported by the new API that is currently in development?

well, at some point yes! But we still have no ETA for that, sorry

1 Like

Yes! for this feature. Would love to see this feature implemented where we can filter nested/fields in modular blocks.

YES please, huge yes and thank you for putting this to a vote Stefano.

Just wanted to throw in my two cents, I think this is a must have feature as well. Thanks

1 Like

Just wanted to bump this, it would be very helpful

Any updates on this? This issue initially was posted back in 2018 :frowning: :pensive:

No sorry, while we know this feature is highly requested it’s also very demanding in term of development for us. So we prefer to spend time on other areas first, but we’ll come to this at some point, sorry!

We are really looking forward to get the deep filtering as well - it is a bit of blocker for us when it comes to suggesting DatoCMS to our clients. Is there any ETA on when this can be added?

not yet sorry @digital.admin

We are about to release the Nested Blocks that was higher up in terms of requests and we are surely going to consider this soon. But we don’t have any ETA yet, sorry.

Any update pls? lots of limitations in CDA.

any updates on this? this has been here since 2018

One more wish for this feature!

Any updates on that?