Forum Discussion
NithyanandSulegai2
Feb 27, 2025Copper Contributor
Dynamically executing a child pipeline using a single Execute Pipeline activity with a variable
Goal: Create a master pipeline that: Retrieves metadata using a lookup. Calculates a value (caseValue) from the lookup result. Maps the value (caseValue) to a pipeline name using a JSON string (p...
petevern
Mar 08, 2025Brass Contributor
Did you pass the parameters as part of the body of the web activity?
- Lookup Activity > fetching metadata (pipeline name + parameters)
- Output example:
{
"pipelineName": "LoadOrdersPipeline",
"parameters": {
"orderDate": "2025-03-08",
"region": "EU"
}
}
- Output example:
- Set variable
- pipelineName: @activity('LookupActivity').output.firstRow.pipelineName
- parametersJson: @string(activity('LookupActivity').output.firstRow.parameters)
- Web Activity
- Example URL: https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataFactory/factories/{dataFactoryName}/pipelines/@{variables('pipelineName')}/createRun?api-version=2018-06-01
- Method: POST
- Headers: Content-Type: application/json
- Body (dynamic content)
- {
"parameters": @variables('parametersJson')
}
- {
- Authenticate via MI or SP