The applyCurrentDocumentTo constraint property in the sheet configuration restricts query results to items within the current LiveDoc. It can target the root entity type or a downstream (related) entity type.
Property
Type
Default
Description
constraints.applyCurrentDocumentTo
string
null
Entity type name to apply current document filtering. When set, the specified entity type is filtered to only include items from the same document as the current Polarion document context.
In this example, SystemRequirement entities are filtered to only those within the current document, while UserNeed entities are not document-constrained.
Full document path in folder/name format. Set automatically from the Powersheet widget’s document context.
currentDocConstraint
string
null
Entity type name or expansion path that should be document-filtered. Derived from applyCurrentDocumentTo configuration.
document.id
string
null
Full document path (folder/name) added as a query parameter for dynamic value resolution.
The query manager automatically injects document context parameters into all queries. These parameters do not need to be set manually in the sheet configuration.
The query manager applies document filtering by injecting predicates into the where clause:
The defaultQueryFragment is computed once from the data source configuration
For each query, the fragment is merged into the query via deep-left merge
If currentDocConstraint matches the query’s from entity type, document.moduleFolder and document.moduleName predicates are injected into the where clause
For server-side document resolution, the query engine constructs Lucene queries to find specific documents:
Input
Format
Example
Project ID + document path
Space/DocumentName
Requirements/SystemReqs
Lucene query
project.id:"proj" AND moduleFolder:"Space" AND moduleName:"DocName"
Full resolution query
The document query format expects Space/DocumentName and splits on the slash character to build separate moduleFolder and moduleName predicates. Verify document path formats match your Polarion project structure.