DEA-C02 Data Transformation Practice Question
A data engineer is transforming a table with a column `tags` stored as a VARIANT array of strings. The goal is to produce one row per tag for downstream aggregation. Which function should be used to expand the array into rows?
⚠ Common exam trap
Test-takers frequently confuse array-to-string conversion or JSON parsing with actual unnesting, which requires the FLATTEN table function.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
FLATTEN(input => tags)
FLATTEN is the Snowflake table function that unnests semi-structured arrays and objects into relational rows. When applied to a VARIANT array, it returns one row per element, making it the correct choice for expanding `tags` into individual rows. The other functions either concatenate, parse, or extract object keys, none of which achieve the required row-level expansion.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
OBJECT_KEYS(tags)
Why it's wrong here
OBJECT_KEYS returns the keys of a VARIANT object, not the elements of an array. Applying it to an array will not produce the tag values and is the wrong function for this scenario. It is used when working with JSON objects to list their attribute names.
- ✗
ARRAY_TO_STRING(tags, ',')
Why it's wrong here
ARRAY_TO_STRING concatenates array elements into a single delimited string. It does not produce one row per element, so it cannot be used to expand the array into multiple rows for aggregation. This function is useful for display or export, but not for row-level transformation.
- ✓
FLATTEN(input => tags)
Why this is correct
FLATTEN is a table function that expands a VARIANT array into one row per element, exposing the value in a VALUE column. It is the standard Snowflake construct for unnesting arrays and is exactly what is needed to transform the `tags` array into rows for downstream aggregation.
- ✗
PARSE_JSON(tags)
Why it's wrong here
PARSE_JSON converts a string containing JSON into a VARIANT value. Since `tags` is already a VARIANT array, this function does not expand it into rows and may even fail or return the same array. It is used for parsing raw JSON strings, not for unnesting arrays.
About these practice questions
Courseiva writes every DEA-C02 question from scratch — 229 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed September 2026 · checked against the official Snowflake exam blueprint
This DEA-C02 practice question is part of Courseiva's free Snowflake certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DEA-C02 exam.