I have a collection called "user_personal_info" which has attributes like. $id, name, age, etc. I have another collection called. "user_professional_info" which has attribute like $id, worktype, city_name etc.. I have more similar related collection. the common thing between this collection is that all document in this collection share the common $id.
My question is..
- how to write query to fetch the doucments who are between the age of 25 to 30 and whose city is "bangalore" and then filter it down further. because all information are in different different collection.
- how pagination would work in this situations. because with above approach each collection would have its own results sets with paginated data.
What I am basically looking for is chaining of Query between mutliple collection without making multiple api calls. essentialy passing the result of one collection to another to refine my results. currently I believe query chaining between collection doesnt work.
let me know if I am wrong..
unfortunately, you can't do this at the moment. maybe after we add additional support for querying relationships, this will be possible
any workaround...?? you can suggest. also is work already going on to have this feature in appwrite ??
I guess this is a very common scenario many people would face.
I guess you could first query one, then query the other, then only keep records that are in both responses
Or combine data into a single collection
this is okay if there are two or 3 collection with less data but when there is more than 5 collection with huge data.. thats a huge task. only better way is to combine in one collection.
Absolutely
This is a serious problem, which made me stop all the projects I was migrating to appwrite, I have to display the related objects according to the status of those objects...
I made an alternative solution using cloud functions, but it’s bad to imagine that it’s something temporary and it gives the feeling that it’s going to explode at any moment...
I know that the team is dedicated and has its concerns, but this is a mandatory thing when working with related data, I hope to see this soon or that they give it a high priority...
Because I love the appwrite...
Recommended threads
- self-hosted auth: /v1/account 404 on saf...
Project created in React/Next.js, Appwrite version 1.6.0. Authentication works in all browsers except Safari (ios), where an attempt to connect to {endpoint}/v1...
- delete document problems
i don't know what's going on but i get an attribute "tournamentid" not found in the collection when i try to delet the document... but this is just the document...
- Attributes Confusion
```import 'package:appwrite/models.dart'; class OrdersModel { String id, email, name, phone, status, user_id, address; int discount, total, created_at; L...