-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Open
Labels
a/api/graphqlc/serverRelated to serverRelated to serverk/enhancementNew feature or improve an existing featureNew feature or improve an existing featurep/highcandidate for being included in the upcoming sprintcandidate for being included in the upcoming sprints/triagedThis has been reviewed by HasuraThis has been reviewed by Hasurat/native-dbstriage/4-rfc-publishedThe RFC is published and comments are requestedThe RFC is published and comments are requested
Description
First, thank you very much for your work on Hasura, its a great product.
There is a feature that I would be very happy to have, wanted to know what are your thoughts on it.
Currently there Is a nested insert feature. However having only an insert without update is not very useful.
Do you have plans to implement update for nested objects?
IMO, the logic would have to be:
I. for lists (1:N)
- for every relation record:
- If it is present in input, not present in the db, then insert the record and link it to owning record
- If it is present in db, not present in input, the delete it
- If it is present in db and is present in input, then update its columns
II. For objects (belongsTo)
- if relation record has an ID, link it to master and update its values
- if relation record has no ID, then create it
- if relation record is not present in input, but is present in db, then unlink it (an option to delete it would be nice)
Thank you
donaldaverill, alaarihan, anasvn, razakpm, renato and 118 moreanasvn, RodolfoSilva, beepsoft, 18601673727, nik-paushkin and 12 morefollowbl, BayCo, vieron, dulara1994, yasinarik and 10 morealaarihan, RodolfoSilva, anasvn, emdagon, 18601673727 and 10 more
Metadata
Metadata
Assignees
Labels
a/api/graphqlc/serverRelated to serverRelated to serverk/enhancementNew feature or improve an existing featureNew feature or improve an existing featurep/highcandidate for being included in the upcoming sprintcandidate for being included in the upcoming sprints/triagedThis has been reviewed by HasuraThis has been reviewed by Hasurat/native-dbstriage/4-rfc-publishedThe RFC is published and comments are requestedThe RFC is published and comments are requested