-
Notifications
You must be signed in to change notification settings - Fork 2
Open
Labels
spec:bugChange fixing a bug in the specification (class 3) –see also spec:substantiveChange fixing a bug in the specification (class 3) –see also spec:substantive
Description
FILTER expressions apply to the whole group graph pattern in which they appear. The algebra operators to perform filtering are added to the group after translation of each group element. We collect the filters together here and remove them from group, then [apply them to the whole translated group graph pattern](https://www.w3.org/TR/sparql12-query/#sparqlAddFilters).
In this step, we also translate graph patterns within FILTER expressions [EXISTS](https://www.w3.org/TR/sparql12-query/#func-filter-exists) and [NOT EXISTS](https://www.w3.org/TR/sparql12-query/#func-filter-not-exists).
Let FS := empty set
For each form FILTER(expr) in the group graph pattern
In expr, replace NOT EXISTS{P} with fn:not(exists(translate(P)))
In expr, replace EXISTS{P} with exists(translate(P))
FS := FS ∪ {expr}
End
The set of filter expressions FS is [used later](https://www.w3.org/TR/sparql12-query/#sparqlAddFilters).
There is no definition of that in means here.
For example, why is the filter in the query below
SELECT ?x WHERE {
?x :a :b .
MINUS { ?x :c :d . FILTER (?x = :w) }
}
not in the main group graph pattern of the SELECT?
Metadata
Metadata
Assignees
Labels
spec:bugChange fixing a bug in the specification (class 3) –see also spec:substantiveChange fixing a bug in the specification (class 3) –see also spec:substantive