You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Dot notation operations are stored as the literal operation object on Postgres instead of being applied #10828
On Postgres, a create or update that applies certain dot notation operations to a nested field stores the raw operation object, for example {"__op": "Add", "objects": ["b"]}, into that field instead of applying the operation. The save response and every later read then return the operation object in place of the real value, so the stored data is corrupted for all callers. MongoDB applies the operations correctly.
Affected on Postgres:
Add, AddUnique and Remove on a one-level nested array field, for example stats.list.
Increment nested two or more levels deep, for example stats.deep.n. A single-level Increment such as stats.views is applied correctly.
In addition, sibling keys under the corrupted parent can be lost: updating stats.deep.n drops stats.deep.m.
Steps to reproduce
Uses the master key.
Nested array operation:
POST /classes/Thing with body {"stats": {"list": ["a"]}}
PUT /classes/Thing/<objectId> with body {"stats.list": {"__op": "Add", "objects": ["b"]}}
GET /classes/Thing/<objectId>
Deeply nested Increment:
POST /classes/Thing with body {"stats": {"deep": {"n": 1, "m": 2}}}
PUT /classes/Thing/<objectId> with body {"stats.deep.n": {"__op": "Increment", "amount": 1}}
GET /classes/Thing/<objectId>
Actual Outcome
stats.list is {"__op": "Add", "objects": ["b"]} instead of ["a", "b"]. The same happens for AddUnique and for Remove (a Remove on an absent parent also stores the literal operation object).
stats.deep is {"n": {"__op": "Increment", "amount": 1}} instead of {"n": 2, "m": 2}: n holds the operation object and the sibling m is lost.
Expected Outcome
The operation is applied to the nested value, so stats.list is ["a", "b"] and stats.deep is {"n": 2, "m": 2}, as on MongoDB.
Environment
Server
Parse Server version: 9.10.7-alpha.1
Operating system: macOS
Local or remote host (AWS, Azure, Google Cloud, Heroku, Digital Ocean, etc): local
Database
System (MongoDB or Postgres): Postgres (MongoDB not affected)
Database version: 16 with PostGIS 3.5
Local or remote host (MongoDB Atlas, mLab, AWS, Azure, Google Cloud, etc): local
Client
SDK (iOS, Android, JavaScript, PHP, Unity, etc): REST API
ℹ️ You can help us to fix this issue faster by opening a pull request with a failing test. See our Contribution Guide for how to make a pull request, or read our New Contributor's Guide if this is your first time contributing.
Related: #10827 — on MongoDB the same dot notation operations instead return HTTP 500 when the resulting field is absent from the write result. Different root cause, tracked separately.
changed the title [-]Dot notation Add, AddUnique and Remove are stored as the literal operation object on Postgres[/-][+]Dot notation operations are stored as the literal operation object on Postgres instead of being applied[/+]on Oct 23, 2026
Correction: this is broader than the original title. Beyond Add/AddUnique/Remove on a one-level nested array, a nested Increment two or more levels deep (e.g. stats.deep.n) is also stored literally and drops sibling keys under the parent. A single-level Increment (stats.views) is applied correctly. Title and description updated.
Activity
parse-github-assistant commentedon Oct 23, 2026
🚀 Thanks for opening this issue!
ℹ️ You can help us to fix this issue faster by opening a pull request with a failing test. See our Contribution Guide for how to make a pull request, or read our New Contributor's Guide if this is your first time contributing.
mtrezza commentedon Oct 23, 2026
Related: #10827 — on MongoDB the same dot notation operations instead return HTTP 500 when the resulting field is absent from the write result. Different root cause, tracked separately.
[-]Dot notation Add, AddUnique and Remove are stored as the literal operation object on Postgres[/-][+]Dot notation operations are stored as the literal operation object on Postgres instead of being applied[/+]mtrezza commentedon Oct 23, 2026
Correction: this is broader than the original title. Beyond
Add/AddUnique/Removeon a one-level nested array, a nestedIncrementtwo or more levels deep (e.g.stats.deep.n) is also stored literally and drops sibling keys under the parent. A single-levelIncrement(stats.views) is applied correctly. Title and description updated.