Question 400
A fraud analytics service receives nested JSON events with evolving attributes. An auditor must prove the outcome of Use a supported `parse_json`-style expression for VARIANT for this requirement: Raw JSON strings should be parsed as structured variant values before querying fields. Which test result is best?
Explanation
Correct Answer
The acceptance criterion for “Raw JSON strings should be parsed as structured variant values before querying fields” is Subsequent path queries return correctly typed or cast results; this is the expected evidence after Use a supported `parse_json`-style expression for VARIANT.
Incorrect Answers
That observation is a valid indicator for “An optional JSON property is missing and the query must not crash” when using Use null-safe path extraction with explicit default handling. The scenario instead tests “Raw JSON strings should be parsed as structured variant values before querying fields”; the relevant result is Subsequent path queries return correctly typed or cast results.
This signal belongs to the adjacent case “A variable list of event objects must be expanded to one row per contained item,” whose remedy is Use supported variant explosion or array expansion functions. The observed result for the present requirement is Subsequent path queries return correctly typed or cast results.
This signal belongs to the adjacent case “An analyst needs to read a nested customer identifier from a VARIANT value,” whose remedy is Use supported variant-path extraction or accessor expressions. The observed result for the present requirement is Subsequent path queries return correctly typed or cast results.