Hi there, I have a table containing a relation column with a one-to-many relationship to another table. When Using TablesDB.GetRow in "node-appwrite" i get all the normal rows but not the relations. Does anyone have an idea?
By default, Appwrite returns only a row's own fields when you retrieve rows. Related rows are not automatically loaded
Use the * wildcard to load all fields from related rows:
const doc = await tablesDB.getRow({
databaseId: '<DATABASE_ID>',
tableId: '<TABLE_ID>',
rowId: '<ROW_ID>',
queries: [Query.select(['*', 'reviews.*'])]
});
https://appwrite.io/docs/products/databases/relationships#performance-loading
I'll try it. Thanks in advance ๐
It worked.... Thanks a lot
[SOLVED] Get Relations when using TablesDB
Recommended threads
- TEAM INVITE
There is a problem with the team invitation. When a user invites other users, that time, the newly created email address they don't get the invite link and old ...
- education plan not activated
Hi I have an edu id 13103046@iubat.edu but when I am trying to claim my plan and trying to logging with github where education student plan active. the appwrite...
- I'm getting an error on the console "j?....
On my self hosted instance version 1.8.1 the console is giving me this error when trying to view the rows for a table I recently created. My application is read...