Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GraphQL field filtering is using the wrong field index #17323

Open
gvkries opened this issue Jan 9, 2025 · 1 comment
Open

GraphQL field filtering is using the wrong field index #17323

gvkries opened this issue Jan 9, 2025 · 1 comment

Comments

@gvkries
Copy link
Contributor

gvkries commented Jan 9, 2025

Describe the bug

When filtering content items in GraphQL by indexed content fields, the field name and part are not considered. This issue arises when multiple fields of the same type are added to a content type, leading to incorrect items being returned. Specifically, querying one field may inadvertently include values from another field of the same type.

Orchard Core version

2.x and newer

To Reproduce

  1. Enable indexing for content fields.
  2. Create a content type with two fields of the same kind (e.g., two numeric fields).
  3. Create content items with different values in each field.
  4. Perform a GraphQL query for one of the fields.
  5. Observe that the query results incorrectly include values from the other field.

Expected Behavior

The GraphQL query should only return items that match the specified field and part, without including values from other fields of the same type.

Logs and screenshots

image

@Piedone Piedone added the GraphQL label Jan 9, 2025
@sebastienros sebastienros added this to the 3.x milestone Jan 9, 2025
Copy link
Contributor

github-actions bot commented Jan 9, 2025

We triaged this issue and set the milestone according to the priority we think is appropriate (see the docs on how we triage and prioritize issues).

This indicates when the core team may start working on it. However, if you'd like to contribute, we'd warmly welcome you to do that anytime. See our guide on contributions here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants