Hi, I have two tables ‘CommentThreads’ and ‘HelpComments’. ‘CommentThreads’ have a list of ‘HelpComments’ objects in it, now I want to add data in ‘HelpComments’ table, how can I add new child object and set the parentId?
As far as I know, I have to save new ‘HelpComment’ object in the database then I can add the new comment’s object in ‘CommentThreads’ table. But for this, I have to call Backendless Data Services three times, First to create the new comment. then to retrieve ‘CommentThreads’ object and then to update ‘CommentThreads’ object after adding the new comment in it.
Can I do the same in a single API call or better than the above mentioned?
Waiting for reply.
Hello,
do you use backendless 4.0 ?
No, I’m using backendless 3
You can retrieve ‘CommentThreads’ object with relations to ‘HelpComment’, then create HelpComment, add it to CommentThreads, save CommentThreads
So, I can’t save HelpComment’s object and set parent object of the saved HelpComment’s object ?
no, you can not
Thanks