On 10/11/2023 20:35, Marco Neumann wrote:
On Fri, Nov 10, 2023 at 5:51 PM Andy Seaborne <[email protected]> wrote:
On 10/11/2023 12:33, Marco Neumann wrote:
Should DELETE {URI URI * } not update all matching graph patterns?
No.
(and that's bad syntax)
I had a case where only DELETE {URI URI NODE } did execute the update in
the dataset/graph/query fuseki UI.
To be precise it is a DELETE INSERT combination with an empty WHERE
clause.
DELETE {pattern} INSERT{pattern} WHERE{ }
the "pattern" is used as a template.
DELETE {template} INSERT {template} WHERE {pattern}
If the template has variables, these variables must be set by the WHERE
clause. Otherwise triple patterns with unbound variables are skipped.
OK, yes I think this is my case, an unbound variable was used in the
template, the "Update Success" tricked me into believing that the data was
actually removed.
"Update Success" means "executed as per spec" :-)
It's the same rule as CONSTRUCT which skips triples with any unbound
variables.
Andy
There is no pattern matching in a template.
There is a short form DELETE WHERE { pattern } which is
DELETE { pattern } WHERE {pattern}, using the pattern as the template.
Andy
Marco