# Retrieve Articles having specific category

**URL:** <https://community.prismic.io/t/retrieve-articles-having-specific-category/14810>\
**Category:** Developing with Prismic\
**Tags:** ruby, graphql\
**Created:** [December 21, 2023, 3:14pm UTC](https://community.prismic.io/t/retrieve-articles-having-specific-category/14810 "2023-12-21T15:14:48Z")\
**Posts on this page:** 1\
**Showing post:** 3

<div class="post-metadata">

**Author:** ![Phil](https://dub1.discourse-cdn.com/flex013/user_avatar/community.prismic.io/phil/32/14_2.png) [@Phil](https://community.prismic.io/u/Phil)\
**Post date:** [December 21, 2023, 5:12pm UTC](https://community.prismic.io/t/retrieve-articles-having-specific-category/14810/3 "2023-12-21T17:12:35Z")

</div>

Hi @haideralifsd786 ,

Welcome to the community!

For this you'll need the filter method:

> [@Query by content relationship](https://community.prismic.io/t/query-by-content-relationship/6366/8):
>
> Hey Kris, I didn't realize at first that you where using Gatsby. In this case, it is not a where argument what you need. You'll use [the filter argument](https://prismic.io/docs/technologies/arguments-filter-sort-limit-skip-gatsby) to get all the docs that match a given Id. Take a look at this new example query { allPrismicAcademyPost(filter: {data: {author: {id: {eq: "YP2kyhAAAB8AuuiO"}}}}) { edges { node { data { author { id } } } } } }

---

_[View the full topic](https://community.prismic.io/t/retrieve-articles-having-specific-category/14810)._
