Databricks Certified Data Engineer Professional Practice Test 54
Question 530
A data engineer at Riverbend Energy must troubleshoot this case: a four-task Lakeflow Job has one failed downstream task after three predecessors succeeded. Evidence: Operators rerun the entire job and duplicate completed side effects. What should be inspected first to confirm the failure mechanism?
- Inspect pipeline event log update IDs and error messages
- Inspect failed task state and which predecessors completed successfully
- Inspect executor stderr and driver logs near the failed stage
- Inspect effective grants on source, target and parent containers for the run-as principal
Explanation
Correct Answer
B:Inspect failed task state and which predecessors completed successfully. This checks the specific evidence behind operators rerun the entire job and duplicate completed side effects. Repair runs can rerun failed or selected tasks while preserving successful predecessor work under supported semantics. The investigation distinguishes the mechanism from an unrelated operational symptom.
Incorrect Answers
A:Inspect pipeline event log update IDs and error messages. This diagnose action addresses a different case (lakeflow event error classes), where the only visible dashboard status is FAILED without a dataset name. Pipeline event logs identify failing update and dataset messages. In the stated problem, operators rerun the entire job and duplicate completed side effects; this choice would not establish the required repair failed tasks decision.
C:Inspect executor stderr and driver logs near the failed stage. This diagnose action addresses a different case (cluster log diagnostics), where the notebook cell shows only a generic stage failure. Driver and executor logs often contain the exact import or JVM error. In the stated problem, operators rerun the entire job and duplicate completed side effects; this choice would not establish the required repair failed tasks decision.
D:Inspect effective grants on source, target and parent containers for the run-as principal. This diagnose action addresses a different case (job run permission debug), where the run-as principal lacks MODIFY on the target table. Unity Catalog authorization applies to the job execution identity. In the stated problem, operators rerun the entire job and duplicate completed side effects; this choice would not establish the required repair failed tasks decision.
Question 531
At Redwood Civic Services, an engineer can edit every shared notebook in a production workspace. Architecture constraint: The team needs read-only access for most users. Which design best addresses this requirement?
- Use supported workspace network restrictions in addition to UC data permissions
- Assign a dedicated production service principal with only required grants
- Use group-based least-privilege workspace object permissions
- Apply a governed column mask while preserving needed analytic access
Explanation
Correct Answer
C:Use group-based least-privilege workspace object permissions. This design addresses the team needs read-only access for most users. Workspace object permissions can restrict who can edit or manage shared code. It establishes the right contract or architecture before execution changes.
Incorrect Answers
A:Use supported workspace network restrictions in addition to UC data permissions. This design action addresses a different case (ip-based workspace restrictions), where a Unity Catalog table grant does not restrict web-console network entry. Workspace access controls and data-object privileges address different security layers. In the stated problem, the team needs read-only access for most users; this choice would not establish the required workspace object acl decision.
B:Assign a dedicated production service principal with only required grants. This design action addresses a different case (service principal access), where the individual's credentials create unnecessary privilege and lifecycle risk. Production automation should use least-privilege service principals for stable identity. In the stated problem, the team needs read-only access for most users; this choice would not establish the required workspace object acl decision.
D:Apply a governed column mask while preserving needed analytic access. This design action addresses a different case (column masking), where a raw SELECT on an approved table exposes plaintext email. Unity Catalog column masks can transform sensitive values at read time. In the stated problem, the team needs read-only access for most users; this choice would not establish the required workspace object acl decision.
Question 532
A deployment owner at Horizon Travel needs to implement a remedy: a source produces multiple records for each business key. The present failure is: The pipeline picks an arbitrary record instead of the newest sequence. Which change should be applied?
- Declare CDC keys, sequence and delete semantics in the supported Lakeflow API
- Use assertDataFrameEqual and assertSchemaEqual in isolated tests
- Include the unique tie-breaker in the supported sequence expression
- Use row_number over the window and retain only rank one
Explanation
Correct Answer
D:Use row_number over the window and retain only rank one. This directly changes the feature or logic behind the pipeline picks an arbitrary record instead of the newest sequence. ROW_NUMBER ordered by a deterministic sequence within each key selects the desired latest row. It is the concrete configuration for the stated incident.
Incorrect Answers
A:Declare CDC keys, sequence and delete semantics in the supported Lakeflow API. This implement action addresses a different case (auto cdc keys), where applying events as append-only rows leaves outdated active accounts. AUTO CDC or applicable APPLY CHANGES needs stable keys and sequence ordering for stateful upserts. In the stated problem, the pipeline picks an arbitrary record instead of the newest sequence; this choice would not establish the required window latest record decision.
B:Use assertDataFrameEqual and assertSchemaEqual in isolated tests. This implement action addresses a different case (dataframe testing), where tests only assert that the DataFrame is nonempty. DataFrame equality and schema assertions test data behavior and contracts. In the stated problem, the pipeline picks an arbitrary record instead of the newest sequence; this choice would not establish the required window latest record decision.
C:Include the unique tie-breaker in the supported sequence expression. This implement action addresses a different case (cdc duplicate sequence), where the processing order for tied source events is nondeterministic. A deterministic sequencing contract needs a unique ordered event position. In the stated problem, the pipeline picks an arbitrary record instead of the newest sequence; this choice would not establish the required window latest record decision.
Question 533
A data engineer at Silver Ridge Logistics must troubleshoot this case: a data engineering job accesses a protected external API. Evidence: An API token is committed in a Python notebook tracked in Git. What should be inspected first to confirm the failure mechanism?
- Locate hard-coded secrets in code and job parameters without printing token contents
- Inspect repository paths and bundle deployment definitions for hard-coded workspace identifiers
- Inspect wheel contents, import paths and the task's installed package version
- Use the physical plan to locate Python evaluation operators
Explanation
Correct Answer
A:Locate hard-coded secrets in code and job parameters without printing token contents. This checks the specific evidence behind an API token is committed in a Python notebook tracked in Git. Secret-backed configuration avoids embedding credentials in notebooks or deployment YAML. The investigation distinguishes the mechanism from an unrelated operational symptom.
Incorrect Answers
B:Inspect repository paths and bundle deployment definitions for hard-coded workspace identifiers. This diagnose action addresses a different case (bundle repository layout), where source files and deployment definitions are coupled to one developer workspace. A versioned Declarative Automation Bundle defines code and resource configurations separately from the target workspace. In the stated problem, an API token is committed in a Python notebook tracked in Git; this choice would not establish the required secure configuration decision.
C:Inspect wheel contents, import paths and the task's installed package version. This diagnose action addresses a different case (python wheel packaging), where a refactor broke a notebook-relative import in the deployed job. A properly packaged versioned wheel gives Python code stable import paths outside notebooks. In the stated problem, an API token is committed in a Python notebook tracked in Git; this choice would not establish the required secure configuration decision.
D:Use the physical plan to locate Python evaluation operators. This diagnose action addresses a different case (avoid python udf for sql), where the Python UDF creates an avoidable cross-language execution boundary. Built-in Spark SQL functions can execute in optimized expressions without Python UDF overhead. In the stated problem, an API token is committed in a Python notebook tracked in Git; this choice would not establish the required secure configuration decision.
Question 534
At Vantage Security, an events table has high-cardinality device IDs and unpredictable daily volumes. A change was deployed to address: Partitioning by device would produce many tiny partitions. Which test result provides the strongest evidence that the requirement is now met?
- Run representative queries and verify selected layouts improve skipping
- Run representative device filters and compare data skipping
- Confirm partition scan count falls with equal query results
- Reconcile changed rows and compare scanned file counts
Explanation
Correct Answer
B:Run representative device filters and compare data skipping. This tests the expected result against partitioning by device would produce many tiny partitions, not simply whether a job or object exists. Liquid clustering organizes data by useful filter keys without high-cardinality partition directories.
Incorrect Answers
A:Run representative queries and verify selected layouts improve skipping. This validate action addresses a different case (automatic clustering), where manual clustering keys quickly become stale. Automatic liquid clustering can select keys using query workload when platform prerequisites are met. In the stated problem, partitioning by device would produce many tiny partitions; this choice would not establish the required liquid clustering cardinality decision.
C:Confirm partition scan count falls with equal query results. This validate action addresses a different case (partition pruning), where a query wraps business_date in a transformation and reads many partitions. Direct predicates on partition keys can enable partition pruning. In the stated problem, partitioning by device would produce many tiny partitions; this choice would not establish the required liquid clustering cardinality decision.
D:Reconcile changed rows and compare scanned file counts. This validate action addresses a different case (predicate-limited merge), where the merge scans unrelated historical partitions. Constraining merge matches to relevant partitions can reduce unnecessary target scanning. In the stated problem, partitioning by device would produce many tiny partitions; this choice would not establish the required liquid clustering cardinality decision.
Question 535
At Arbor Medical, an engineering team installs a compiled Python wheel on job compute. A change is required because: The wheel works on a developer laptop but fails with a binary compatibility error. Which implementation action most directly corrects the configuration?
- Deploy the wheel task with its documented entrypoint and parameters
- Replace the Python UDF with Spark SQL built-in functions
- Install a compatible platform wheel rather than the desktop-only artifact
- Use assertDataFrameEqual and assertSchemaEqual in isolated tests
Explanation
Correct Answer
C:Install a compatible platform wheel rather than the desktop-only artifact. This directly changes the feature or logic behind the wheel works on a developer laptop but fails with a binary compatibility error. Compiled extensions must match the target runtime platform and Python ABI. It is the concrete configuration for the stated incident.
Incorrect Answers
A:Deploy the wheel task with its documented entrypoint and parameters. This implement action addresses a different case (python task entrypoints), where the task exits before setting up its argument parser. A standard Python entrypoint and explicit arguments avoid notebook runtime assumptions. In the stated problem, the wheel works on a developer laptop but fails with a binary compatibility error; this choice would not establish the required wheel abi compatibility decision.
B:Replace the Python UDF with Spark SQL built-in functions. This implement action addresses a different case (avoid python udf for sql), where the Python UDF creates an avoidable cross-language execution boundary. Built-in Spark SQL functions can execute in optimized expressions without Python UDF overhead. In the stated problem, the wheel works on a developer laptop but fails with a binary compatibility error; this choice would not establish the required wheel abi compatibility decision.
D:Use assertDataFrameEqual and assertSchemaEqual in isolated tests. This implement action addresses a different case (dataframe testing), where tests only assert that the DataFrame is nonempty. DataFrame equality and schema assertions test data behavior and contracts. In the stated problem, the wheel works on a developer laptop but fails with a binary compatibility error; this choice would not establish the required wheel abi compatibility decision.
Question 536
Quality assurance at Fairhaven Transport checks a corrected workload where a silver pipeline must select the newest account event per key. The original fault was: Two events have the same event time and yield different surviving rows. Which verification is most decisive?
- Verify an order with four items yields four item-level rows
- Read old and new records and verify null semantics for the new field
- Compare known local times from two regions against the same UTC instant
- Shuffle source row order and verify the same account record survives
Explanation
Correct Answer
D:Shuffle source row order and verify the same account record survives. This tests the expected result against two events have the same event time and yield different surviving rows, not simply whether a job or object exists. A deterministic tie-breaker is required in a per-key window ranking.
Incorrect Answers
A:Verify an order with four items yields four item-level rows. This validate action addresses a different case (array explosion), where an order-level aggregation mistakenly treats the array as a single item. explode creates item-level rows when the business grain requires each array element. In the stated problem, two events have the same event time and yield different surviving rows; this choice would not establish the required latest-per-key with ties decision.
B:Read old and new records and verify null semantics for the new field. This validate action addresses a different case (controlled schema evolution), where the silver writer rejects every new record after the upstream schema change. Schema evolution must be reviewed rather than enabling unrestricted acceptance for every column. In the stated problem, two events have the same event time and yield different surviving rows; this choice would not establish the required latest-per-key with ties decision.
C:Compare known local times from two regions against the same UTC instant. This validate action addresses a different case (timestamp timezone normalization), where events from different regions are ordered incorrectly in a UTC dashboard. Time-zone normalization is required before comparing timestamps from different sources. In the stated problem, two events have the same event time and yield different surviving rows; this choice would not establish the required latest-per-key with ties decision.
Question 537
At Harborline Utilities, a consumer group needs sales totals but not transaction-level customer IDs. The known risk is: Granting SELECT on the raw fact table violates minimization. After remediation, which ongoing signal best detects recurrence?
- Monitor view grants and changes to projected columns
- Monitor new external-location grants and credential usage
- Monitor attempts to change or bypass column masks
- Audit unauthorized changes to workspace objects
Explanation
Correct Answer
A:Monitor view grants and changes to projected columns. This watches the failure mode described by granting SELECT on the raw fact table violates minimization. A governed aggregation view can expose only approved derived information. It supplies a regression signal after remediation.
Incorrect Answers
B:Monitor new external-location grants and credential usage. This monitor action addresses a different case (storage credential scope), where engineers propose a credential allowing access to all company buckets. Unity Catalog storage credentials and external locations can constrain storage access. In the stated problem, granting SELECT on the raw fact table violates minimization; this choice would not establish the required secure view sharing decision.
C:Monitor attempts to change or bypass column masks. This monitor action addresses a different case (column masking), where a raw SELECT on an approved table exposes plaintext email. Unity Catalog column masks can transform sensitive values at read time. In the stated problem, granting SELECT on the raw fact table violates minimization; this choice would not establish the required secure view sharing decision.
D:Audit unauthorized changes to workspace objects. This monitor action addresses a different case (workspace object acl), where the team needs read-only access for most users. Workspace object permissions can restrict who can edit or manage shared code. In the stated problem, granting SELECT on the raw fact table violates minimization; this choice would not establish the required secure view sharing decision.
Question 538
At Oak Valley Retail, a production Delta table needs obsolete data files cleaned up. The known risk is: An operator proposes aggressive VACUUM retention during active long-running readers. After remediation, which ongoing signal best detects recurrence?
- Monitor serverless task failures and cost per run
- Monitor retention changes and cleanup failures
- Monitor query duration and Photon operator usage
- Monitor managed table optimization and ownership changes
Explanation
Correct Answer
B:Monitor retention changes and cleanup failures. This watches the failure mode described by an operator proposes aggressive VACUUM retention during active long-running readers. VACUUM retention must protect older snapshots still needed by readers and streams. It supplies a regression signal after remediation.
Incorrect Answers
A:Monitor serverless task failures and cost per run. This monitor action addresses a different case (serverless job fit), where provisioning overhead exceeds useful task execution time. Supported serverless jobs can reduce infrastructure management and startup overhead. In the stated problem, an operator proposes aggressive VACUUM retention during active long-running readers; this choice would not establish the required vacuum retention safety decision.
C:Monitor query duration and Photon operator usage. This monitor action addresses a different case (photon query execution), where an unsupported execution mode limits vectorized engine use. Photon can accelerate supported SQL and DataFrame operators on compatible compute. In the stated problem, an operator proposes aggressive VACUUM retention during active long-running readers; this choice would not establish the required vacuum retention safety decision.
D:Monitor managed table optimization and ownership changes. This monitor action addresses a different case (managed table maintenance), where each table has custom file cleanup jobs and broad storage permissions. Unity Catalog managed tables provide platform-managed data placement and maintenance capabilities. In the stated problem, an operator proposes aggressive VACUUM retention during active long-running readers; this choice would not establish the required vacuum retention safety decision.
Question 539
At Horizon Travel, a source produces multiple records for each business key. Architecture constraint: The pipeline picks an arbitrary record instead of the newest sequence. Which design best addresses this requirement?
- Define validated region and catalog parameters for each invocation
- Define environment-specific target values without forking business logic
- Define a deterministic window partitioned by key and ordered by event sequence
- Define a composite or otherwise unique ordering key for competing CDC events
Explanation
Correct Answer
C:Define a deterministic window partitioned by key and ordered by event sequence. This design addresses the pipeline picks an arbitrary record instead of the newest sequence. ROW_NUMBER ordered by a deterministic sequence within each key selects the desired latest row. It establishes the right contract or architecture before execution changes.
Incorrect Answers
A:Define validated region and catalog parameters for each invocation. This design action addresses a different case (job parameters), where code contains hard-coded region IDs and catalog names. Task parameters allow runtime-specific values without changing notebook source. In the stated problem, the pipeline picks an arbitrary record instead of the newest sequence; this choice would not establish the required window latest record decision.
B:Define environment-specific target values without forking business logic. This design action addresses a different case (bundle target overrides), where development job arguments were deployed into the production target. Bundle targets can override environment-specific variables and resource settings. In the stated problem, the pipeline picks an arbitrary record instead of the newest sequence; this choice would not establish the required window latest record decision.
D:Define a composite or otherwise unique ordering key for competing CDC events. This design action addresses a different case (cdc duplicate sequence), where the processing order for tied source events is nondeterministic. A deterministic sequencing contract needs a unique ordered event position. In the stated problem, the pipeline picks an arbitrary record instead of the newest sequence; this choice would not establish the required window latest record decision.
Question 540
A data engineer at Fairhaven Transport must troubleshoot this case: a repository change breaks SQL transformations in the production bundle. Evidence: The deployment pipeline only checks YAML syntax. What should be inspected first to confirm the failure mechanism?
- Review Python version, wheel tags and package resolution logs
- Inspect executor stderr and driver logs near the failed stage
- Inspect pipeline event log update IDs and error messages
- Inspect CI stages for tests, bundle validation and approvals
Explanation
Correct Answer
D:Inspect CI stages for tests, bundle validation and approvals. This checks the specific evidence behind the deployment pipeline only checks YAML syntax. CI must run transformation tests and controlled integration checks before deployment. The investigation distinguishes the mechanism from an unrelated operational symptom.
Incorrect Answers
A:Inspect Python version, wheel tags and package resolution logs. This diagnose action addresses a different case (python dependency triage), where a package import error appears only on the target compute. Runtime-specific wheel compatibility and pinning must be tested in CI. In the stated problem, the deployment pipeline only checks YAML syntax; this choice would not establish the required ci quality gates decision.
B:Inspect executor stderr and driver logs near the failed stage. This diagnose action addresses a different case (cluster log diagnostics), where the notebook cell shows only a generic stage failure. Driver and executor logs often contain the exact import or JVM error. In the stated problem, the deployment pipeline only checks YAML syntax; this choice would not establish the required ci quality gates decision.
C:Inspect pipeline event log update IDs and error messages. This diagnose action addresses a different case (lakeflow event error classes), where the only visible dashboard status is FAILED without a dataset name. Pipeline event logs identify failing update and dataset messages. In the stated problem, the deployment pipeline only checks YAML syntax; this choice would not establish the required ci quality gates decision.