JingsongLi commented on code in PR #11163:
URL: https://github.com/apache/paimon/pull/11163#discussion_r4643629567


##########
docs/docs/primary-key-table/merge-engine/aggregation.mdx:
##########
@@ -268,6 +268,10 @@ count of distinct event IDs.
    - `error`: Throw an exception if the nested-key contains null values, 
because primary key fields must not be null.
 
   Use `fields.<field-name>.nested-sequence-field=seq0,seq1,...` to control the 
update sequence of a nested table, you must configure 
`fields.<field-name>.nested-key` when using it.
+  Multi-field sequences are compared lexicographically in configuration order 
(nulls first). A nested ROW is overwritten when its sequence is greater
+  than the accumulated one; when sequences are equal, overwrite behavior is 
controlled by
+  `fields.<field-name>.nested-sequence-overwrite-on-equal` (default `true`). 
Set it to `false` to overwrite only when the new sequence is strictly greater.

Review Comment:
   The same direct SQL route also ignores the policy on writes. With the false 
option, I registered an Arrow temp table containing the two equal-sequence 
versions and ran `INSERT INTO t SELECT * FROM paimon.default.probe`. The 
command reports two input rows, and reopening through the corrected Python 
table reader returns only `second`. This requires a SQL write guard or Native 
support before writing as well.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to