﻿# Azure AI Search collection predicates share a bound item

Azure AI Search binds predicates inside one complex-collection lambda to the same item; separate any filters or fielded text matches can select evidence from different items.

Author: Retrivium editorial team
Updated: 2026-11-04
Canonical URL: https://retrivium.ai/journal/guide-azure-search-correlated-collection-filter/
Language: en

## Express the same-item requirement first

A source record contains a collection of document editions, each with language and publication status. The application needs an edition that is both in the requested language and published. Azure AI Search's [collection-operator reference](https://learn.microsoft.com/en-us/azure/search/search-query-odata-collection-operators) uses `any` with a bound range variable. Put both conditions inside the same complex-item predicate when the requirement concerns one edition satisfying them together.

## Distinguish separate existential conditions

The [collection-filter explanation](https://learn.microsoft.com/en-us/azure/search/search-query-understand-collection-filters) describes correlated predicates for complex collections. Separate `any` clauses can instead be satisfied by different items: an unpublished edition in the requested language and a published edition in another language. Both document-level conditions are true, yet no usable edition meets the original request. The difference is logical scope, not a ranking defect or evidence that the search service ignored one filter.

## Do not transfer full-text matching into the correlation rule

The same guide explains that fielded full-text search over a complex collection is uncorrelated across its subdocuments. Matching terms in different edition fields does not establish that those terms belong to the same edition. Choose a correlated filter for the exact same-item constraints and treat text relevance separately. [Filtering and ranking](/journal/milvus-text-match-bm25-filter-ranking/) provide a related distinction: a strong text match does not prove the requested structured relationship held.

## Check the collection type before rewriting

The [troubleshooting reference](https://learn.microsoft.com/en-us/azure/search/search-query-troubleshoot-collection-filters) lists restrictions on lambda expressions, including unsupported full-text functions there and different forms for simple collection types. A Boolean rewrite valid for a complex item is not automatically valid for a string or numeric collection. Use the field's actual schema and supported operators. Preserve the intended logical meaning rather than move conditions outside a lambda merely to make a rejected expression syntactically acceptable.

## Inspect the qualifying item, not only the document

For a matched source, identify the edition that satisfies the full bound predicate. [Tool observations](/journal/learn-codex-tool-observation/) should retain that structured evidence. A result set can then be assessed against the same-item requirement instead of counting any document with independently matching properties as accepted. This makes the filter useful for selecting a genuinely usable edition and prevents a plausible search result from silently changing the user's requested language-and-status relationship.
