
hey guys, i have this project where user create a post and users can like a post, but now, i cant seem to be able to count the number of likes, it seem like Appwrite did not provide the option to actually count attribute or document
please guys, how do i do this??

For that the best way would be to move the counting up logic into a function
And, if you don't want same user like more than once, then you'll be best creating another collection named likes
with relationship to the each post with unique key composed from user id and post id.
Recommended threads
- My collection is not updating after csv ...
- How do I format an array in a CSV file t...
I want to import a CSV file to create a document on it on the AppWrite website. I have an attribute "name" of type String and "ingredients" which is of type St...
- my database attribute stuck in processin...
when i created attributes in collection 3 of those attributes become "processing", and they are not updating, the worst thing is that i cant even delete them s...
