HarperFast / HarperFast/harper
SQL UPDATE SET on a nested-object column silently no-ops (column unchanged, no error)
- Dominant language
- JavaScript
- Stars
- 89
- Forks
- 10
- Avg merge
- 2d 6h
- Merged PRs (30d)
- 200
Description
## Summary
A SQL `UPDATE tbl SET profile='...' WHERE id=?` targeting a nested-object (structured type) column is accepted with no error but the stored record is **unchanged** — the SET is silently ignored. Simple scalar columns update correctly.
## Observed behavior
```sql
-- profile is a nested-object column {name, address, prefs}
UPDATE Person SET profile='{"name":"new"}' WHERE id='p1';
-- Response: 200, no error
-- Actual result: record still holds the original profile value
```
REST and ops-API `update` correctly replace the top-level attribute (shallow merge via `Object.assign`). Only SQL is affected.
## Impact
A developer issuing a SQL UPDATE to set a structured/nested column gets silent data loss — the intended change is not applied, with no indication of failure. The 200 response with no error makes this hard to notice.
## Repro
```
npm run test:integration -- "integrationTests/qa-scratch/qa113-deep-merge.test.ts"
```
Harper commit: `7aaa5a152`. Applies to the SQL path when the SET target is a structured/object-typed column.
## Suggestion
Either reject `SET col = ` on nested-object columns with a clear error (making the no-op loud), or document that SQL UPDATE only applies to top-level simple/scalar columns and structured attributes must be updated via REST/ops.
*Found by the automated QA explorer campaign (wave 34). 🤖 Generated with [Claude Code](https://claude.com/claude-code)*
Contributor guide
Assessment
This issue has not been assessed yet.