Hi All,
I have three output streams in my workflow for three different cases. I have to output them in 3 different sheets of the same excel.
I have used three Block Until Done tools in the following way:
First time when I ran it, it gave the output as desired in three different sheets in the same excel file.
However, the next time I ran it, it gave an error. I have tried some fixes like keeping no space between sheet names. The path of the file is also correct.
The errors keep changing and I get the output file but only one or two of the sheets are there. The errors also keep changing.
Error: Output Data (95): Unable to open file for write: - Attempt to open a file that is already open: The process cannot access the file because another process has locked a portion of the file. (33)
Unable to create backup of UBR.xlsx.bak: Access is denied. (5)
Can someone please help me on how to fix these errors? Or, can recommend any other way to get the desired output?
Solved! Go to Solution.
Block until done doesnt work that way. Its meant for one to many type situations. The items on the 1 output anchor would finish before the items on the 2 output would start, and so on.
Having three blocks with only one connection each is no different than going straight from the formula to the output tool.
As far as work arounds, there are a few things that can be tried depending on what we are working with. The big question on what route we take is, are all the columns the same in each of those branches? Is the only difference that the sheet names are different?
If they are all the same columns and only the sheet is different, you can use a single output tool to write to all 3. If they are different, then we have to go a different route.
Refer to the following discussion
Thanks @SPetrie Some of the columns would be different in the three sheets. Plus, the three streams are the 3 outputs of a Join tool.
Will be very helpful if you could recommend a way to do it.
@pereisyd I tried the solution provided in the the link that you sent. It runs fine but at the end the output is not being written to the folder I specified. Do you know what can be the reason? Also, after Union, Left Join output is taking the columns present in the Right Join output. I do not want this in the final output.
@SPetrie good shout there is only a need for 1 block until tool regardless of the join tool or not as the way the outputs are currently set up the block until dones are not really doing anything
@Deano478 How would you suggest to go about it then? Can you please give an example, if possible?
Can you share the configuration of Output tool
@Dheeru28 Can I ask at the moment why not just create the sheets in the output tool the overwrite them when new data comes in?
@Deano478 Do you mean separate output tools for separate sheets? If yes, that is something that I can do.
But I'm looking for a way if I can get the 3 sheets in just one file as output.