I have used an until activity to copy files in a sequential order. For this I have created a variable and assigned the value 0 and compared it against the number of files available in the data lake. The expression used in the until activity checks if the variable values is greater than the number of files, till the variable value becomes greater than the count of files, the loop executes. If no files found in the data lake then the variable value would be set to 1 and the the count of files would be 0. But what happens is , even if the value of variable is 1 and count of files is zero the until activity activity tries to execute the inner activities. Any solution for this? The condition activity used to set the variable value: @equals(activity(lookup).output.firstrow.NumberOfFiles,0) then set variable var1 =1 else 0 the expression used in until activity : @greater(int(variables('var1')),activity(lookup).output.firstrow.NumberOfFiles) Inside the until activity: Set the variable to increment the var1 value by 1
If any suggestions, would be really helpful
Regards, Sandeep
According to Microsoft documentation,the Until activity provides the same functionality that a do-until looping structure provides in programming languages.
It will first execute inner activities one time ,and then according to the result of expression to decide to loop or break.
So in your situation,your inner activities will execute once and then get the
truevalue and break the until activity.If your don't want to execute once,you can use another
If Condition activityand letvar1 = 1don't execute the util activity.