Forum Discussion
Fabric Data Factory system variable pipeline().triggertype
Hello
I would be grateful if someone from Microsoft would clarify whether, for Fabric Pipelines, the system variable pipeline.triggertype() is officially supported.
Our pipeline is set up to be triggered by a schedule.
At the moment, on pipeline run, when we pass the value of the system variable pipeline.triggertype() through to our own logging tables, it returns the value of either Manual or 1.
This is different to what is stated in the pipeline development user interface, which shows that it passes through value of either Manual or Scheduler.
Also in the documentation below re pipeline scope variables for Fabric data factory, no mention is made of the system variable pipeline.TriggerType()
https://learn.microsoft.com/en-us/fabric/data-factory/expression-language#pipeline-scope-variables
Please clarify if the values of Manual and 1 currently being passed through are a reliable means to determine whether the pipeline was a manual or scheduled trigger - or will these values be subject to change?
If not reliable, I will have to develop a manual work around.
Many thanks for your help in anticipation.
Hi JaneLHunt,
Thank you for reaching out to Microsoft Fabric Community.
Currently @pipeline().TriggerType is available in Azure Data Factory, but it is not listed as a supported system variable for Fabric Data Factory pipelines. That is why its returned value should not be relied upon to distinguish between manual and scheduled runs.
As a workaround, create a pipeline parameter such as RunType with Manual as its default value. In the schedule configuration, pass Scheduled to this parameter, and access it using: @pipeline().parameters.RunType
Fabric supports passing parameter values from each schedule, so this is currently the most reliable way to distinguish manual and scheduled runs.
Thanks and regards,
Anjan Kumar Chippa
2 Replies
Hi JaneLHunt,
Thank you for reaching out to Microsoft Fabric Community.
Currently @pipeline().TriggerType is available in Azure Data Factory, but it is not listed as a supported system variable for Fabric Data Factory pipelines. That is why its returned value should not be relied upon to distinguish between manual and scheduled runs.
As a workaround, create a pipeline parameter such as RunType with Manual as its default value. In the schedule configuration, pass Scheduled to this parameter, and access it using: @pipeline().parameters.RunType
Fabric supports passing parameter values from each schedule, so this is currently the most reliable way to distinguish manual and scheduled runs.
Thanks and regards,
Anjan Kumar ChippaHello v-achippa
Thank you for your prompt reply and clarifying that the returned values from @pipeline().triggertype cannot be relied on.
I will use the manual work around
Best regards
Jane Hunt