Looking for efficient GraphQL mutation format to delete something along the lines of: Author (id 123) and all of that author’s Posts (and potentially other nested item types within Posts, such as Media…).
I see year old posts on here which seem to come to the conclusion that it’s not possible via a single, cascading GraphQL mutation. So questions:
-
Has this changed since a year ago?
-
What is the best non-DQL, GraphQL-only way to go about this on Dgraph Cloud?
A) Is it to delete each type separately and specify each and every node id? Author {id: 123} and Posts [{id: 234}, {id: 567}…] and Media[{id:789},{id:0123]…?
B) Is it to delete each type separately: Delete Media filtered where associated Posts = [{id: 234}, {id: 567}…] and Delete Posts filtered where associated Author = {id: 123} and Delete Author {id: 123}…?
Ah yes, looks like Dgraph still does not allow deep filtering so it seems B is not possible.
C) Or is there now a deep/cascading method for mutations?
Thanks.