ADF throws an error while using boolean variables in functions expecting bool parameters

Tamer Kadioglu 1 Reputation point

Hi Everyone,

I have an adf project with git so have different data factories mostly with the same codes.
What I'm trying to do and having different results between data factories is really simple.

I have 2 variables, types are boolean.


I am seeting those from db without an issue and using them in a pipeline as a parameter.


Now it works this way BUT before it was set to the values of the variables and it was working in our dev data factory, when we release the code to staging df, it threw an error:


And I sense that there is a conversion problem between boolean variable type and bool type because as below you can see that json gets the values as string, "true", not true (without quotes)


I think it should be working with assigning only variable values, any idea why I got different results between different data factories?
Can be because of df settings too but any idea on this?

Best Regards

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,730 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. ShaikMaheer-MSFT 38,126 Reputation points Microsoft Employee

    Hi @Tamer Kadioglu ,

    Thank you for posting query on Microsoft Q&A Platform.

    Your variables in Master pipeline are declared as Boolean type already. Hence you no need to convert them again to bool using bool() function. Kindly pass your variables as it is in to Parameters of your child pipeline. Make sure, you declare your parameters in child pipeline as Boolean too.

    Please check below gif where I tried same and it was working fine.


    Hope this will help. Please let us know if any further queries. Thank you.


    • Please accept an answer if correct. Original posters help the community find answers faster by identifying the correct answer. Here is how.
    • Want a reminder to come back and check responses? Here is how to subscribe to a notification.