One to Many Moralis objects

I canā€™t figure out how to save my child obj to parent.
I have Parent obj, Parent has many child.
I checked a lot of examples, I used EF core in.net before, So I thought itā€™s something similar.
How can I insert a child object into a Parent? Can anyone share react code with me?
For example, Parent has objectId, TokenList what is relational to child.
Child has TokenId, Description.

You can find an example here https://v1docs.moralis.io/moralis-dapp/database/objects#many-to-many-relationships

You can use relation in that case and using relation.add() to add more children to the parent relation

Sorry, I didnā€™t get how it should work.
So does it mean if my Parent has a pointer to _User. Parent has relation to Children.
code would look like
const user = Moralis.User.current();
const relation = user.relation(ā€œParentā€);
relation.add(children)
user.save();
???
Only one example in the documentation, itā€™s hard for me to figure outā€¦

Where children here is an Object ( ParseObject )

Sorry I canā€™t understand you.If my example above is right , Iā€™m totally confused.
If I have objectId of Parent, Why do I need to query user?
Can I add Children to parent only based on objectId of Parent?

For example, I used UI dashboard to achieve that without code.
I created 2 childs , and I canā€™t attach them to Parent

For that forEach error, hard refreshing the page should work.

Can I schedule a call with someone from the Moralis team, to show and receive any help for my products, Cuz I used your solution and Iā€™ve thoughts that development would be faster, but it doesnā€™t look like so ,for now.

I wonā€™t give up. Iā€™ll place my solution here when it succeeds

About UI dashboard, bug exists. If I go to the relation row via a dashboard, I canā€™t see any records. When I refreshed the page, records appears. Where I can report the bug?

Hey mate, okay I got it. I successfully created child in parent.
I donā€™t need user. Actually I can query all relations by entity which has relation type.
Would be cool to see more examples in docs, cuz itā€™s rly simple but Iā€™ve spent 2 days for it.
Can I query all child data that are link to Parent?

Or do I need to select all childs which have Parents equal to objId?

You can query Parent, get the child relation, and .query on the realtion should return the children

Can you, please, provide an example?

For example you have a post with a comment realtion holding many comments, you can get the comment from the relation in such way.

const Post = Moralis.Object.extend("Post");
const postQuery = new Moralis.Query(Post);
let post = await postQuery.first()  // Get first Post

// Comment Relation on Post
const commentRelation = post.relation("comment")
const commentsQuery = commentRelation.query()
const commentsInRelation = await commentsQuery.find()
2 Likes