
Hi, I have a posts collection with few relationship attributes like Categories, Tags, and Author. Now I want to fetch posts of specific Author, Tags, Or Categories. Is this possible? And also use other features like Appwrite Queries.

Queries on relationships are not supported.

Okay. Then how can I do what I want to do? If i don't use relationships then displaying all posts in backend will be difficult. After fetching all posts I have to loop all documents and make multiple fetch requests. Adds a lot of latency and it is not a good experience for both dev and client.

I don't think additional queries are that bad. That said, if you really need to query on categories, tags, and author, I would maybe include the author name, and a string for categories and a string for tags. Then, id use the search query

Okay. I will test it

Anyway. Is it possible to use Appwrite select query to not return just one attribute? E,g: select("-title")

If there is, then I can use two-way relationship and avoid relationship attributes where not required using the select query.

Even this will not allow me to do pagination and run queries on posts relationship attribute of tags collection. But this is what i can think of

No

No, because queries on relationships are not supported

Okay. I hope small and important features like this get added to Appwrite ASAP. E.g - Upsert documents and Queries on Relationship
Recommended threads
- Is there migration script generation lik...
Having standards migration script is helpful. For example something like same script to apply for multiple DB - each DB for one tenant
- Querying and filtering on relationship a...
Hello! A few short months ago, we decided to migrate from SupaBase over to Appwrite, because we were experiencing a lot of headache with the former when it fina...
- Appwrite Upgrade 1.6.1 → 1.7.4
Just upgraded my Appwrite instance from 1.6.1 → 1.7.4 and ran into some issues during the migration process. What I did: - Upgraded Appwrite to 1.7.4 - Imported...
