Description
N1QL provides the
UPDATE SET / UNSET ... FOR ...
syntax for updating nested array elements. However, this only supports one array level. We need to support additional array levels by chaining the FOR clauses. See user request at
https://forums.couchbase.com/t/how-to-add-new-field-to-each-element-of-array-which-is-inside-another-array/8509/5
http://stackoverflow.com/questions/37538047/n1ql-how-to-add-new-field-to-each-element-of-array-which-is-inside-another-arr/37546122#37546122
Attachments
Issue Links
- blocks
-
MB-19612 4.5.1 Minor Release
- Closed
For Gerrit Dashboard: MB-19857 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
64781,2 | MB-19857. UPDATE elements of deeply nested arrays by chaining FOR clauses in UPDATE ... SET / UNSET ... FOR ... statements. | master | query | Status: MERGED | +2 | +1 |
66640,2 | MB-19857. Allow ARRAY_FLATTEN() to be used with UPDATE SET ... FOR ... This supports update of deeply nested arrays. | master | query | Status: MERGED | +2 | +1 |
66641,2 | MB-19857. Allow ARRAY_FLATTEN() to be used with UPDATE SET ... FOR ... This supports update of deeply nested arrays. | watson | query | Status: MERGED | +2 | +1 |