A Data Engineer is using the following query to work with semi-structured data:
What is the output?
FLATTEN uses KEY for object-member names and INDEX for array-element positions. Recursive flattening returns rows for all nested elements; filtering for INDEX IS NULL retains the object-member rows. The THIS LIKE '%Onyx%' condition selects the object containing Onyx, producing one row for each of its three keys: species, name, and is_dog.
FLATTEN
KEY
INDEX
INDEX IS NULL
THIS LIKE '%Onyx%'
Onyx
species
name
is_dog
Community Discussion