# Remove tm:secondaryOrganisation when it equals org:organization.
# Affects 230 memberships.

PREFIX tm:  <https://daniel.degu.cl/ontologies/theatre-migrants/>
PREFIX org: <http://www.w3.org/ns/org#>

DELETE {
  ?s tm:secondaryOrganisation ?secondary .
}
WHERE {
  ?s a org:Membership .
  ?s org:organization ?primary .
  ?s tm:secondaryOrganisation ?secondary .
  FILTER(?primary = ?secondary)
}
