I have relational db so that multiple clients can be added to an agreement, i have created the many to one relation in appwrite db, but i don't know how upload clients when using, createDocument() function?
Maybe this will help: https://appwrite.io/docs/databases-relationships#create-documents
You can also create the documents as assign via ID of the document
How to create related documents
Furthermore, I am able to pass the related document ID when creating a relation with documents. However, this only works with the "Two-way relationship" option. If I try to do the same with the "One-way relationship" option, I receive an error.
Please create a separate post with details like your code, your collections, and the error message
@Steven thanks, I figured it out, I had to pass a list of client ids.
@rafaat Can I mark this as solved?
Or you need help with anything else?
@D5 thanks, you can mark it.
[SOLVED] How to create related documents
Recommended threads
- Apple OAuth Scopes
Hi Hi, I've configured sign in with apple and this is the response i'm getting from apple once i've signed in. I cant find anywhere I set scopes. I remember se...
- Sign In With Apple OAuth Help
Hi All! I've got a flutter & appwrite app which Im trying to use sign in with apple for. I already have sign in with google working and the function is the sam...
- Type Mismatch in AppwriteException
There is a discrepancy in the TypeScript type definitions for AppwriteException. The response property is defined as a string in the type definitions, but in pr...