i am making a schema like this:
title: String,
description: String,
image: String,
members: [String],
where members is an array of user ids
}
is there any way to reference user in this schema based on collection of registered user
No. When I use user details in my app, I typically create a collection of users. then, I can add any other attribute I need for the user.
Another suggestion I have is to really think about whether you want to use an array for members. Array operations are not supported so you'll need to do a full replace when adding a member. This can be problematic if you have multiple updates going on at the same time
so if i try to implement addition of members in my app, by pushing members in the array. I can't really do it right?
You'd have to fetch the list, push locally, and then update with that full updated list
ok, lets say i create user collection, can i reference it in other collection?
With the current version of cloud, it would be a manual reference. Appwrite 1.3 added support for relationships
Can you tell me about manual reference?
π₯²
Its just a string attribute where you put the ID
Ah okay
[CLOSED] Reference registered details in database
Recommended threads
- Get team fail in appwrite function
I try to get team of a user inside appwrite function, but i get this error: `AppwriteException: User (role: guests) missing scope (teams.read)` If i try on cl...
- Deploy function not working - 503
Hellon i get this error message, when i try to deploy a new version of a function <html><body><h1>503 Service Unavailable</h1>No server is available to handle...
- Error When load the website
Hi, I am getting this error whenever I reload my website please help me, I am using react Error: ** GET https://cloud.appwrite.io/v1/account 401 (Unauthoriz...