Reject invalid unsigned nested input before ClickHouse defaults hide it
Type compatibility cannot approve a nested unsigned array when negative input was replaced by an empty array. Link raw input to the rejection policy and retain the scope of any lost valid siblings.
Conversion failure differs from NULL
Conversion failure and an actual NULL input are different events. A successful load that substitutes a default is not preservation evidence. Truthound Core can inspect a prepared input-acceptance decision after the operator defines unsigned-domain policy. [1, 2, 3]
A whole nested array defaults
ClickHouse issue #129483 reports VALUES turning [[1,-1]] for Array(Array(UInt64)) into [] on 26.7.1.1 and 26.10.3.7, while other text formats reject the input. Follow-ups describe investigation rather than a verified deployed repair. [1]
Retain raw nested input
Preserve format and raw nested value, then detect negatives before unsigned conversion. Under a rejection policy, do not approve invalid input merely because the stored empty array has a valid type. Keep valid sibling elements available in the source record. [1, 3]
Explicitly choose rejection
The illustrative business rule rejects negative UInt64 input. [[1,-1]] contains -1, so expected acceptance=false. false passes; true fails even if the resulting stored value is []. This fixture chooses rejection explicitly rather than calling unsigned wrapping universally correct. [1, 3]
Parsing and policy are external
ConditionalExpressionValidator in Truthound Core Python SDK 3.3.2 can check an operator-prepared invalid-input flag against approval. The operator parses nesting and defines wrapping or rejection. The SDK does not modify VALUES parsing or recover an erased array. [1, 2, 3]
Distinguish rejecting and wrapping paths
Verify a rejecting format or input_format_null_as_default=0 in a controlled environment. A setting that instead wraps -1 is a different policy and requires its own consumer approval. [1, 3]
Keep the conversion cause
Keep raw input, conversion error, and actual NULL distinct in diagnostic records. Otherwise default substitution makes both the offending element and the valid data lost with it disappear from the explanation. [1, 3]
Application conditions
Prepare format, raw nested values, and the approved unsigned policy.
Alternatives
Verify a rejecting format or disabled null_as_default in isolation.
Limitations
Wrapping and rejecting negatives are different policies; defaults do not prove preservation.
Evidence
- Event checked
- Subject checked
- Modified
