Skip to content
Back

Possible to prevent automatic fetching/resolution of relationship documents?

  • 0
  • React Native
  • Cloud
MediMax
16 Apr, 2025, 16:39

When using listDocuments on a parent collection, I'm observing that the response seems to include the full documents from related collections, not just their IDs, which is causing excessive reads. Is there a way to prevent this and ensure only the relationship IDs are returned? Alternatively, understanding that Query.select usually applies only to the parent collection's fields, is there any other Appwrite feature or query mechanism that allows selecting specific attributes (like $id) from linked documents directly within the parent listDocuments call, especially for nested relationships?

TL;DR
Developers are looking to prevent automatic fetching of relationship documents when calling listDocuments on a parent collection to reduce excessive reads. They want to only receive relationship IDs in the response instead of full documents. The goal is to select specific attributes like $id directly within the parent listDocuments call, even for nested relationships.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more