Hello
How can I output to a list from a collection including the relationship to another collection and output these values as well.
Thank you
ex.
` let promise = databases.listDocuments( DB_ID, COLLECTION_ID_PEOPLE, COLLECTION_ID_RECORDS, [ Query.select(["PEOPLE.firstName", "PEOPLE.lastName"], ["RECORDS.title", "RECORDS.text"]) ] );
promise.then(function (response) { console.log(response); }, function (error) { console.log(error); });`
If you are using relationship, you'll always get the relate docs, at the moment you can't query relationship (not supported)
I have just tried that and it works! Something like
const books = await databases.listDocuments('db_id', 'coll_id', [
Query.select(['title', 'author.name'])
]);
[SOLVED] listDocuments with relationship
Recommended threads
- Endless certificate generation cycle
Hello, when I try to add the subdomain stats.hedgehog-rp.ru, I get an infinite loop while the certificate is being generated. There are no problems with adding ...
- Realtime not working for some tables
Hi, I've got an issue where I can setup a realtime connection to listen to some tables, but some not all. I have two tables `history` and `users`. Both can be ...
- How to handle ghost accounts created by ...
Appwrite create the account with the email and send an invitation link with a secret. I am able to accept the invitation and add the account as a member on the ...