Showing results for 
Search instead for 
Did you mean: 
Advocate II
Advocate II

Create Blob in For Each

Does Create Blob not work in a for each action?
Trying to get SQL binary blobs into Azure Storage Blob
I get data from sql database (SQL query (V2)), get the table into an array (Compose- not necessary just makes it cleaner), and then a for each on the compose array.
Inside the for each I set a filename for already initialized variable using ID_name_data from other columns. then I use Compose the content of the blob


doc_bin being sql column that has the blob data, then Create Blob. Create blob itself works a file is created in the container but that's it. One file no matter how many items in array.
Looking at run history everything works in the for each except when it comes to the Create Blob part. The Create Blob has the same file name for all files, so it only creates one file in the blob folder. The filename variable is correct in the set action, but in the Create Blob action it's not. They are different sizes when I click through each item so it doesn't technically 'create' the same file, but it's giving each file the same name, randomly it appears.
What am I doing wrong here?



Advocate II
Advocate II

After HOURS of trying this decided to try setting values inside the action instead of using set variables and it worked. Not sure why, or what the difference is but it is now creating all the files in the for each in Azure Storage Blob. Posting solution here if anyone else runs into issue




But this WORKS





Helpful resources

Process Advisor

Introducing Process Advisor

Check out the new Process Advisor community forum board!

MPA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Top Solution Authors
Users online (53,748)