New Year Sale Special - Limited Time 70% Discount Offer - Ends in 0d 00h 00m 00s - Coupon code: mxmas70

Home > dbt Labs > Analytics Engineers > dbt-Analytics-Engineering

dbt-Analytics-Engineering dbt Analytics Engineering Certification Exam Question and Answers

Question # 4

In development, you want to avoid having to re-run all upstream models when refactoring part of your project.

What could you do to save time rebuilding models without spending warehouse credits in your next command?

A.

Replace your {{ ref() }} functions with hard-coded references.

B.

Refer to a manifest and utilize the --defer and --state flags.

C.

Clone your upstream models from the production schema to the development schema.

D.

Leverage artifacts from a prior invocation by passing only the --state flag.

Full Access
Question # 5

Which statement is true regarding source freshness checks?

Choose 1 option.

A.

The freshness check can be disabled with freshness: null.

B.

A source freshness check will always exit immediately after the first failure.

C.

dbt source freshness should always be the final command in a run.

D.

dbt build will automatically run source freshness checks.

Full Access
Question # 6

The dbt_project.yml file contains this configuration:

models:

+grants:

select: ['reporter']

How can you grant access to the object in the data warehouse to both reporter and bi?

A.

{{ config(grants = { '+select': ['bi'] }) }}

B.

{{ config(grants = { 'select': ['+bi'] }) }}

C.

{{ config(grants = { 'select': ['bi'], 'inherits': true }) }}

D.

{{ config(grants = { 'select': ['bi'], 'include': ['dbt_project.yml'] }) }}

Full Access
Question # 7

Match the desired outcome to the dbt command or argument.

Full Access
Question # 8

Which two code snippets result in a lineage line being shown in the DAG? Choose 2 options.

A.

{{ source('source', 'table') }}

B.

{{ ref('stg_jaffle_shop__customers') }}

C.

dbt_jsmith.stg_jaffle_shop__customers

D.

{{ target.schema }}

E.

{{ source('jaffle_shop.customers') }}

Full Access
Question # 9

Examine the code:

select

left(customers.id, 12) as customer_id,

customers.name as customer_name,

case when employees.employee_id is not null then true else false end as is_employee,

event_signups.event_name,

event_signups.event_date,

sum(case when visit_accomodations.type = 'hotel' then 1 end)::boolean as booked_hotel,

sum(case when visit_accomodations.type = 'car' then 1 end)::boolean as booked_ride

from customers

-- one customer can sign up for many events

left join event_signups

on left(customers.id, 12) = event_signups.customer_id

-- an event signup for a single customer can have many types of accommodations booked

left join visit_accomodations

on event_signups.signup_id = visit_accomodations.signup_id

and left(customers.id, 12) = visit_accomodations.customer_id

-- an employee can be a customer

left join employees

on left(customers.id, 12) = employees.customer_id

group by 1, 2

Full Access
Question # 10

Consider this DAG for a dbt project. You have configured your environment to use one thread.

When running dbt run, you determine that model_d fails to materialize.

How will changing the command from dbt run to dbt run --fail-fast impact the execution of dbt run when model_d fails to materialize? Choose 1 option.

Options:

A.

dbt will attempt to materialize the rest of the models.

B.

dbt will drop the existing version of model_d in the data platform.

C.

dbt will attempt to materialize everything else except for model_f.

D.

dbt will stop building any additional nodes in the DAG.

Full Access
Question # 11

Which two are true for a dbt retry command?

Choose 2 options.

A.

It reruns all nodes in your previous invocation statement.

B.

It retries the previous command if it is not a syntax error in a model.

C.

It picks up from the error without running all of the upstream dependencies.

D.

It reuses selectors from the previous command.

E.

It reads a manifest.json file to identify the models and tests that failed in the last run.

Full Access
Question # 12

Full Access
Question # 13

Examine how freshness is defined at the database level:

- name: raw

database: raw

freshness: # default freshness

warn_after: {count: 12, period: hour}

error_after: {count: 24, period: hour}

loaded_at_field: _etl_loaded_at

How can one table from the source raw be excluded from source freshness?

A.

Add freshness: null to the table configuration.

B.

Since freshness is defined at the source level, all tables in the source must adhere to the freshness parameters.

C.

Add loaded_at_field: null to the table configuration.

D.

Add error_after: null to the table configuration.

Full Access
Question # 14

You want to run and test the models, tests, and snapshots you have added or modified in development.

Which will you invoke? Choose 1 option.

Options:

A.

dbt build --select state:modified --defer

B.

dbt run --select state:modified --defer --state

dbt test --select state:modified --defer --state

C.

dbt build --select state:modified --defer --state

D.

dbt run --select state:modified --state

dbt test --select state:modified --state

E.

dbt build --select state:modified --state

Full Access
Question # 15

You want to configure dbt to prevent tests from running if one or more of their parent models is unselected.

Which test command should you execute?

Choose 1 option.

A.

dbt test --select "orders" --indirect-selection=empty

B.

dbt test --select "orders"

C.

dbt test --select "orders" --indirect-selection=buildable

D.

dbt test --select "orders" --indirect-selection=cautious

Full Access
Question # 16

You are building an incremental model.

Identify the circumstances in which is_incremental() would evaluate to True or False.

Full Access
Question # 17

Given this dbt_project.yml:

name: "jaffle_shop"

version: "1.0.0"

config-version: 2

profile: "snowflake"

model-paths: ["models"]

macro-paths: ["macros"]

snapshot-paths: ["snapshots"]

target-path: "target"

clean-targets:

- "logs"

- "target"

- "dbt_modules"

- "dbt_packages"

models:

jaffle_shop:

orders:

materialized: table

When executing a dbt run your models build as views instead of tables:

19:36:14 Found 1 model, 0 tests, 0 snapshots, 0 analyses, 179 macros, 0 operations, 0 seed files, 0 sources, 0 exposures, 0 metrics

19:36:16 Concurrency: 1 threads (target='default')

19:36:17 Finished running 1 view model in 3.35s.

19:36:17 Completed successfully

19:36:17 Done. PASS=1 WARN=0 ERROR=0 SKIP=0 TOTAL=1

Which could be a root cause of why the model was not materialized as a table?

The target-path is incorrectly configured.

A.

Yes

B.

No

Full Access
Question # 18

Which two configuration items can be defined under models: in your dbt_project.yml file?

Choose 2 options.

A.

schema

B.

source

C.

tags

D.

test

E.

target

Full Access
Question # 19

You wrote this test against your fct_orders model to confirm status filters were properly applied by a parent model:

{{

config(

enabled=true,

severity='error'

)

}}

select *

from {{ ref('fct_orders') }}

where status_code = 13

Which statement about this test is true?

A.

You must attach the test to the model in orders.yml for it to run.

B.

This test will warn instead of erroring when you use the --warn-error flag.

C.

The file must be saved in the tests/generic directory.

D.

Records with status_code = 13 will cause this test to fail.

Full Access