All Snowflake exams
Free DEA-C02 practice test: 30 questions with answers
30 original questions for SnowPro Advanced: Data Engineer, drawn from every topic area. Answer each one to see whether you got it right and why. No sign-up.
- Free questions
- 30
- Full bank
- 100 questions
All 30 DEA-C02 questions with answers
The same questions as the test above, grouped by exam topic. Open any question to see the answer and explanation.
Data movement (6 questions)
Question 1
A team loads new JSON files that land in an external stage every few minutes. The load should happen automatically as each file arrives, without a scheduled warehouse job. Which feature should be used?
- AA manual PUT command run by hand every hour
- BA nightly COPY INTO run that loads the files in a scheduled batch
- CSnowpipe with auto-ingest on the stage notifications
- DA stored procedure polling the stage each second
Show answer and explanationHide answer
Correct answer: CSnowpipe with auto-ingest loads files as they arrive using event notifications, so it is continuous and serverless. Nightly jobs, manual PUTs and polling procedures add latency and operational work.
Question 2
A data engineer needs to bulk load several terabytes of historical CSV files from cloud storage into a table in one job, using warehouse compute. Which command should be used?
- ACOPY INTO the table from the stage with appropriate file format options
- BSELECT * FROM the stage to query the files without loading data
- CCREATE VIEW over the staged files that exposes them as a virtual table
- DINSERT statements sent one row at a time from the client tool
Show answer and explanationHide answer
Correct answer: ACOPY INTO loads files in bulk using warehouse compute and file format options. Selecting from a stage does not load data, row inserts are slow for bulk loads, and views do not store data.
Question 3
A pipeline loads files with COPY INTO, and a few files contain bad records. The team wants the load to continue for good files while the bad records are reported. Which option supports this?
- AON_ERROR set to ABORT_STATEMENT so one bad row halts the load
- BDeleting the bad files from the stage before loading them
- CTurning off the load history tracking for the target table
- DON_ERROR set to CONTINUE with the load history checked for errors
Show answer and explanationHide answer
Correct answer: DON_ERROR CONTINUE loads valid rows and skips bad ones, and load history or validation shows the errors. Aborting on the first error stops the whole load, deleting files loses evidence, and turning off history removes visibility.
Question 4
A team needs to capture row-level changes from a table so that a downstream transformation can process only the new and updated rows. Which feature provides this?
- AA clustering key on the table
- BA search optimization service on the table
- CA zero-copy clone of the table
- DA stream on the table
Show answer and explanationHide answer
Correct answer: DA stream records changes on a table, which downstream tasks use to process only what changed. Clustering keys improve pruning, search optimization speeds lookups, and zero-copy clones copy metadata rather than tracking changes.
Question 5
A task must run a transformation only when a stream has new data, and it should run every five minutes. Which configuration does this?
- AA task set to run every second with no WHEN condition, so it fires even without new data
- BA task with a schedule and a WHEN condition that checks SYSTEM$STREAM_HAS_DATA
- CA view that users query manually whenever a report is needed, which recomputes on each read
- DA stored procedure with no schedule attached, until a caller invokes it
Show answer and explanationHide answer
Correct answer: BA scheduled task with a WHEN condition on SYSTEM$STREAM_HAS_DATA runs only when there is new data, which avoids wasted compute. Running every second wastes credits, views do not schedule, and unscheduled procedures never run automatically.
Question 6
An engineer wants to unload a query result to cloud storage as Parquet files for another system. Which command should be used?
- ACOPY INTO a stage location with the Parquet file format
- BCREATE TABLE AS SELECT that keeps the result in Snowflake
- CSHOW TABLES IN SCHEMA for the query result
- DGET to download the result files to a local laptop folder
Show answer and explanationHide answer
Correct answer: ACOPY INTO a stage location unloads query results to files in the chosen format, including Parquet. Creating tables, showing tables and downloading to a laptop do not export to cloud storage in the required format.
Performance optimization (6 questions)
Question 7
A large table is filtered mostly by event_date and region, and queries scan most micro-partitions. Which action most directly improves pruning?
- AExport the table to CSV
- BIncrease the size of every warehouse permanently
- CConvert the table to a view
- DDefine a clustering key on event_date and region
Show answer and explanationHide answer
Correct answer: DA clustering key co-locates rows with similar values, which improves micro-partition pruning for filters on those columns. Larger warehouses do not change pruning, views do not store data, and CSV exports make queries slower.
Question 8
Point lookups on a very large table by a high-cardinality column are slow. Which feature is designed for this access pattern?
- AA clustering key on a low-cardinality column
- BSearch optimization service on the column
- CA zero-copy clone
- DA larger warehouse only
Show answer and explanationHide answer
Correct answer: BSearch optimization accelerates selective lookups such as equality on high-cardinality columns. A clustering key on a low-cardinality column does not help point lookups, and warehouse size and clones do not change the lookup strategy.
Question 9
A query is slow, and the engineer wants to see where the time is spent by operator, including how many partitions were scanned. Which tool gives this detail?
- AThe Query Profile for the query
- BThe SHOW USERS output
- CThe account's billing dashboard
- DThe network policy list
Show answer and explanationHide answer
Correct answer: AQuery Profile shows operator-level timings, partition pruning and data volumes for a query. Billing dashboards, user lists and network policies do not show query execution detail.
Question 10
A workload has many small queries running at the same time, and they queue during peak hours. Which warehouse setting helps absorb the concurrency?
- AA multi-cluster warehouse with a scaling policy
- BA larger number of tasks in one stream
- CTurning off auto-resume
- DA single-node warehouse that is always suspended
Show answer and explanationHide answer
Correct answer: AA multi-cluster warehouse adds clusters when queries queue, which absorbs concurrency. A single-node suspended warehouse, more tasks and disabled auto-resume do not solve queueing.
Question 11
A team wants to reduce credit consumption from an ETL warehouse that is idle for long periods between jobs. Which setting helps?
- ATurning off the warehouse permanently and dropping it
- BKeeping the warehouse running at X-Large size during the business day
- CAuto-suspend after a short idle period with auto-resume enabled
- DCreating a new warehouse for each query submitted
Show answer and explanationHide answer
Correct answer: CAuto-suspend stops idle compute and auto-resume restarts it when needed, which saves credits without blocking jobs. Running at maximum size, permanently off warehouses and a new warehouse per query increase cost or break the workflow.
Question 12
Which two actions can reduce the cost of queries that repeatedly scan the same unchanged data? (Choose two.)
- AMaterialize the expensive result in a materialized view when the pattern repeats
- BScan the full table on every dashboard refresh
- CRely on result caching when queries are identical and the data has not changed
- DDisable all caching to ensure freshness
- EUse a larger warehouse for every query regardless of size
Show answer and explanationHide answer
Correct answer: A, CResult caching returns results for identical queries when data is unchanged, and materialized views precompute repeated expensive results. Full scans, disabled caching and oversized warehouses all increase cost.
Data transformation (6 questions)
Question 13
A transformation must run several SQL steps with conditional logic and loops in one callable unit. Which Snowflake object fits?
- AA materialized view that caches the results of one query
- BA file format that describes CSV, JSON, Parquet or Avro layouts for loading
- CA stored procedure written in SQL scripting, JavaScript or Python
- DA stage holding files in an internal or external location
Show answer and explanationHide answer
Correct answer: CStored procedures can contain multi-step logic with conditions and loops in several supported languages. Materialized views store query results, file formats describe files, and stages hold files.
Question 14
A pipeline needs a nested field from a semi-structured VARIANT column as a typed string. Which expression does this?
- ALOWER(col) only
- BGROUP BY col:field
- Ccol:field::STRING
- DSHOW col
Show answer and explanationHide answer
Correct answer: CThe colon path notation extracts a nested value and the double-colon cast converts it to a type. LOWER does not extract nested fields, GROUP BY groups rows, and SHOW lists objects.
Question 15
A data engineer wants to write DataFrame-style transformation code in Python that runs inside Snowflake close to the data. Which feature supports this?
- ATime Travel
- BFail-safe
- CZero-copy cloning
- DSnowpark
Show answer and explanationHide answer
Correct answer: DSnowpark lets developers write DataFrame-style code in Python, Java or Scala that executes in Snowflake. Time Travel, Fail-safe and zero-copy cloning are data protection or storage features.
Question 16
Which Snowflake object stores a query result and refreshes it automatically to meet a target freshness?
- AA file format for the field delimiter
- BA resource monitor on credits
- CA named stage object for loads
- DA dynamic table with a target lag
Show answer and explanationHide answer
Correct answer: DA dynamic table defines a query whose results are refreshed to meet a target lag. File formats, stages and resource monitors do not maintain query results.
Question 17
An intermediate result is needed only within one session. Which table type fits?
- AA temporary table
- BAn external table
- CA permanent table with Fail-safe
- DA materialized view
Show answer and explanationHide answer
Correct answer: AA temporary table exists only for the session, which suits intermediate results. Permanent tables persist, external tables point at external files, and materialized views maintain results rather than session scratch space.
Question 18
An engineer needs to rename a table without copying its data. Which statement does this?
- ACOPY INTO a new table from every micro-partition of the source
- BALTER TABLE RENAME, which changes only the metadata
- CExporting the table to a stage and reimporting it later
- DCreating a zero-copy clone of the whole database every time
Show answer and explanationHide answer
Correct answer: BRenaming changes metadata only and keeps the data in place. Copying, exporting and cloning the whole database are unnecessary and slower.
Security and governance (6 questions)
Question 19
A salary column must show masked values to most roles and real values to the HR role. Which object enforces this rule?
- AA file format with column delimiter
- BA masking policy applied to the column
- CA secure view with a plain select
- DA warehouse size setting that scales compute
Show answer and explanationHide answer
Correct answer: BA masking policy applied to the column returns masked or real values based on the role, which enforces the rule for every query. A view without conditions, a file format and warehouse sizing do not control column visibility.
Question 20
Sales representatives must see only the rows for the accounts they own in a shared table. Which object enforces this?
- AA row access policy
- BA clustering key
- CA resource monitor
- DA stream object
Show answer and explanationHide answer
Correct answer: AA row access policy filters which rows each role can see based on conditions such as ownership. Clustering keys improve pruning, resource monitors track credits, and streams record changes.
Question 21
A governance team wants to see which users accessed a sensitive table over the last 90 days. Which view provides this history?
- AA clustering key on the table that orders rows by event date
- BThe ACCESS_HISTORY view in the account usage schema
- CAn external stage listing of staged files
- DA resource monitor report that tracks credit usage per warehouse
Show answer and explanationHide answer
Correct answer: BACCESS_HISTORY records which objects were accessed and by whom, which supports audit. Clustering keys, stages and resource monitors do not record object access.
Question 22
A compliance team asks that a sensitive column be readable only by members of a specific role, even for users with table access. Which control enforces this at query time?
- AA comment on the column that labels it as sensitive for data stewards
- BA naming convention that prefixes the column with secret_ for teams
- CA masking policy on the column with a condition on the role
- DTurning off query history for the account so that reads are not logged
Show answer and explanationHide answer
Correct answer: CA masking policy with a role condition enforces the restriction at query time for every user. Comments, naming conventions and disabled query history do not enforce access.
Question 23
A data engineer wants to give a team access to a view that exposes only aggregated results, without granting access to the underlying detailed table. Which object type is appropriate?
- AA temporary table holding a copy of the detailed data
- BA named stage holding the table's exported files
- CA secure view over the detailed table with the aggregation
- DA direct SELECT grant on the detailed base table
Show answer and explanationHide answer
Correct answer: CA secure view exposes only the aggregated result and hides the underlying definition and data, which limits access appropriately. A direct grant on the detailed table, a stage and an unrestricted temporary table expose more than needed.
Question 24
Which two controls help protect personal data in a Snowflake account? (Choose two.)
- ASharing a single account login across the data team
- BCopying personal data into an unrestricted development database
- CDisabling access history monitoring
- DMasking policies that show masked values to unauthorized roles
- ERow access policies that restrict rows to authorized users
Show answer and explanationHide answer
Correct answer: D, EMasking policies and row access policies limit what each role sees, which protects personal data. Shared logins, unrestricted copies and disabled monitoring all weaken protection.
Storage and data protection (6 questions)
Question 25
A table was dropped by mistake, and the engineer must restore it within the retention period. Which feature supports this recovery?
- AA zero-copy clone created after the drop
- BFail-safe, which the customer can invoke directly
- CReloading the table from a CSV file only
- DTime Travel with UNDROP
Show answer and explanationHide answer
Correct answer: DTime Travel with UNDROP restores a dropped table within the Time Travel retention period. Fail-safe is for emergency recovery by Snowflake, clones after the drop cannot recover the original, and reloading from CSV may lose data.
Question 26
After Time Travel expires, data may still be recoverable for a limited period. Which feature provides this, and who can use it?
- AFail-safe, used only by Snowflake for emergency recovery
- BAuto-suspend, used by administrators to pause
- CSearch optimization, used by analysts to speed up point lookups
- DResult caching, used by users with query access
Show answer and explanationHide answer
Correct answer: AFail-safe provides a limited recovery period after Time Travel, and only Snowflake can use it for emergency recovery. Result caching, auto-suspend and search optimization are not recovery features.
Question 27
Which two statements about zero-copy cloning are correct? (Choose two.)
- AA clone initially shares storage with its source
- BCloning always copies all the data physically at creation
- CClones can only be made of external tables
- DChanges made to a clone do not change the source object
- EClones cannot be created in the same schema as the source
Show answer and explanationHide answer
Correct answer: A, DA zero-copy clone shares storage initially, and changes to the clone are stored separately so the source is unaffected. Cloning does not copy data physically at creation, clones are not limited to external tables, and they can be created in the same schema.
Question 28
A team needs a complete copy of a development database to test a migration, with no impact on production storage at the start. Which feature gives this?
- AAn export of every table to CSV
- BZero-copy clone of the database
- CA full backup restored on a new server
- DCopying the data into a spreadsheet
Show answer and explanationHide answer
Correct answer: BA zero-copy clone creates an instant copy that shares storage until changes are made, which suits test environments. CSV exports, full restores and spreadsheets are slower and less practical.
Question 29
A table must keep its history for 30 days so that the team can query previous versions. Which setting should be configured?
- AThe warehouse auto-suspend time set to 30 seconds on a shared compute warehouse
- BThe number of scheduled tasks defined in the database for the nightly load
- CThe internal stage's file size limit and the compression of staged files
- DThe DATA_RETENTION_TIME_IN_DAYS parameter set to 30 on the table
Show answer and explanationHide answer
Correct answer: DDATA_RETENTION_TIME_IN_DAYS controls how long Time Travel history is kept, so setting it to 30 keeps 30 days of history. Warehouse suspension, task counts and stage file limits do not control history retention.
Question 30
Which two statements about Time Travel are correct? (Choose two.)
- AThe Time Travel retention period can be set per table within allowed limits
- BTime Travel is unlimited for every edition with no configuration
- CUsers can restore data after the retention period ends by themselves
- DTime Travel lets users query data as it existed at a past point within the retention period
- ETime Travel keeps no history for dropped tables
Show answer and explanationHide answer
Correct answer: A, DTime Travel allows querying past states within the retention period, and the retention can be set per object within the limits of the edition. It is not unlimited for all editions, users cannot restore on their own after the retention period, and dropped tables can be recovered within the period.