Search code examples
azureazure-data-factoryoracle-adfazure-pipelines-tasks

ADF task modification


@string(equals(substring(pipeline().globalParameters.ENVIRONMENT_ROOT_FOLDER,0,2)),(substring(pipeline().parameters.TargetPath),1,3)))

this throws error :: function 'equals' does not accept 1 argument(s)

  • basically this code wants to check what is current environment and if the target path contains the current environment , this will go to false.
  • For example if i am running this ADF pipeline from DEV and target path contains a path with a location from dev ( say dev\xyz\kty) it will fail /go to false. else it will be true

Solution

  • You can use this :

    @equals(tolower(pipeline().globalParameters.ENVIRONMENT),'prod') 
    

    this resolved the issue