We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello,
Looks like conjunction inside just below Condition Groups is always taking AND, irrespective of conjunction supplied.
Main Query
query ($key: [String]!, $offset: Int!, $limit: Int!, $filters: ConditionGroupInput, $sort: [SortInput]) { searchAPISearch(index_id: "myindex", condition_group: $filters, range: {offset: $offset, limit: $limit}, fulltext: {keys: $key}, sort: $sort) { count: result_count documents { ... on MyindexDoc { group__title content__content_title } } } }
Scenario 1 : Supplied query variables (giving expected result)
{ "offset": "0", "limit": 50, "key": "test", "filters": { "conjunction": "OR", "groups": [ { "conditions": [ { "operator": "=", "name": "content__content_type", "value": "article" }, { "operator": "=", "name": "content__field_is_application", "value": "yes" }, { "operator": "<>", "name": "content__field_life_cycle__entity__name", "value": "Retired" } ] } ] }, "sort": [ { "field": "search_api_relevance", "value": "desc" } ] }
Scenario 2 : Supplied query variables (giving expected result)
{ "offset": "0", "limit": 50, "key": "test", "filters": { "conjunction": "OR", "groups": [ { "conditions": [ { "operator": ">", "name": "group__id", "value": "0" }, { "operator": "<>", "name": "group__field_life_cycle__entity__title", "value": "Retired" }, { "operator": "<>", "name": "group__field_is_live", "value": "0" } ] } ] }, "sort": [ { "field": "search_api_relevance", "value": "desc" } ] }
Scenario 3 : Supplied query variables (giving 0 result, but it should be result of Scenario 1 + Scenario 2)
{ "offset": "0", "limit": 50, "key": "test", "filters": { "conjunction": "OR", "groups": [ { "conditions": [ { "operator": "=", "name": "content__content_type", "value": "article" }, { "operator": "=", "name": "content__field_is_application", "value": "yes" }, { "operator": "<>", "name": "content__field_life_cycle__entity__name", "value": "Retired" } ] }, { "conditions": [ { "operator": ">", "name": "group__id", "value": "0" }, { "operator": "<>", "name": "group__field_life_cycle__entity__title", "value": "Retired" }, { "operator": "<>", "name": "group__field_is_live", "value": "0" } ] } ] }, "sort": [ { "field": "search_api_relevance", "value": "desc" } ] }
What I assume conjunction just above groups always using AND operation between groups objects, but I want to use OR here. Am I doing something wrong?
The text was updated successfully, but these errors were encountered:
Any feedback/comment against this?
Sorry, something went wrong.
No branches or pull requests
Hello,
Looks like conjunction inside just below Condition Groups is always taking AND, irrespective of conjunction supplied.
Main Query
Scenario 1 : Supplied query variables (giving expected result)
Scenario 2 : Supplied query variables (giving expected result)
Scenario 3 : Supplied query variables (giving 0 result, but it should be result of Scenario 1 + Scenario 2)
What I assume conjunction just above groups always using AND operation between groups objects, but I want to use OR here.
Am I doing something wrong?
The text was updated successfully, but these errors were encountered: