nerdexam
Microsoft

DP-700 · Question #77

You have a Fabric workspace that contains a lakehouse named Lakehouse1. You plan to create a data pipeline named Pipeline1 to ingest data into Lakehouse1. You will use a parameter named param1 to…

The correct answer is B. "@pipeline().parameters.param1)". To access an integer pipeline parameter named 'param1' within a Fabric pipeline expression, the parameter is referenced using the dynamic content syntax pipeline().parameters.param1, which inherently returns the value as its defined type.

Ingest and transform data

Question

You have a Fabric workspace that contains a lakehouse named Lakehouse1. You plan to create a data pipeline named Pipeline1 to ingest data into Lakehouse1. You will use a parameter named param1 to pass an external value into Pipeline1. The param1 parameter has a data type of int. You need to ensure that the pipeline expression returns param1 as an int value. How should you specify the parameter value?

Options

  • A"@pipeline().parameters.param1"
  • B"@pipeline().parameters.param1)"
  • C"@@(pipeline().parameters.param1))"
  • D"@@(pipeline().parameters.param1)"

How the community answered

(31 responses)
  • B
    94% (29)
  • C
    3% (1)
  • D
    3% (1)

Why each option

To access an integer pipeline parameter named 'param1' within a Fabric pipeline expression, the parameter is referenced using the dynamic content syntax `pipeline().parameters.param1`, which inherently returns the value as its defined type.

A"@pipeline().parameters.param1"

Option A `("@pipeline().parameters.param1")` is the standard correct syntax for referencing a pipeline parameter within a string field, assuming no extra parenthesis. Given B is marked correct, A would be considered incorrect as per the provided answer key.

B"@pipeline().parameters.param1)"Correct

In Fabric data pipelines, parameters are accessed using the dynamic content syntax `@{pipeline().parameters.<parameterName>}`. For an integer parameter like `param1`, `pipeline().parameters.param1` directly references its integer value. While the extra closing parenthesis in the given option `B` `("@pipeline().parameters.param1)")` is a syntactic anomaly in standard expressions, the core `pipeline().parameters.param1` mechanism ensures the integer type is preserved when correctly used.

C"@@(pipeline().parameters.param1))"

The `@@` prefix is used for escaping the `@` character when the field expects a literal string starting with `@`, not for directly evaluating a dynamic expression. The extra parentheses are also incorrect.

D"@@(pipeline().parameters.param1)"

The `@@` prefix is used for escaping, not for directly evaluating a dynamic expression to return an integer value. The outer `()` are also unnecessary if it is within `@@()`.

Concept tested: Fabric pipeline parameter referencing

Source: https://learn.microsoft.com/en-us/azure/data-factory/control-flow-expression-language-functions#pipeline-parameters

Topics

#Pipeline parameters#Dynamic content#Fabric pipelines#Expression language

Community Discussion

No community discussion yet for this question.

Full DP-700 Practice