-
-
Notifications
You must be signed in to change notification settings - Fork 9.2k
Closed
Description
Bug report
- Node.js version: 16.15.1
- NPM version: 8.11.0
- Strapi version: 4.3.6
- Database: postgreSQL
- Operating system: Windows
Strapi filter: "or" works as "and" in graphql
hello community!
I am troubled while wanted to use complex filter using "or" for two fields.
here firstly I wanted filter by slug and setting an or operator that if the first filter is not working, than the second operator which is filter by itSlug should run.
Screenshots
this single filter is working
this complex query is not working
Code snippets
query category($locale: I18NLocaleCode, $slug: String) {
categories(locale: $locale, filters: {slug: {eq: $slug}, or: [{itSlug: {eq: $slug}}]} ) {
data {
id
attributes {
categoryName
slug
description
locale
}
}
}
}
Metadata
Metadata
Assignees
Labels
No labels

