Skip to content
Back

How to use Operator.arrayAppend on a relationship

  • 0
  • Self Hosted
  • Flutter
  • Databases
Nox
8 May, 2026, 19:45

Hi, is it possible to use any operator on a relationship column? I have a One to Many relationship column on a table and I would like to add entries to the column using the arrayAppend Operator. I'm hosting Appwrite 1.9.0 and using Flutter/Dart SDK. The following snippet:

TypeScript
await databases.updateRow(
        databaseId: AppwriteConstants.databaseID,
        tableId: AppwriteConstants.tableID,
        rowId: id,
        data: {
          "related": Operator.arrayAppend([id])
        }
      );

Fails with the error relationship_value_invalid Thank you!

TL;DR
You cannot use the Operator.arrayAppend method directly on a relationship column in Appwrite. This specific operation is not supported.
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