You are viewing limited content. For full access, please sign in.

Question

Question

Conditional Parallel activity not moving on to the next branch

asked on October 16, 2017

Why is this workflow's Conditional Parallel activity not moving on to the next branch?  I must have tried 20 combinations of configurations now and I am stumped!  

The task is to create shortcuts in correspondence folders based on which choices the users made in the multi-value field called "Corr Filing Choice - To/From" but only if there isn't already a document there with the same name.

Track Tokens shows it is picking up the three values correctly.

Still, every test I run results in only the first value picked up from that field getting a resulting shortcut.  It should be creating three shortcuts in three different folders if the user chose three different values in this field.

In this second example, there were only two values in the field, which activated the second branch but still, it only created one shortcut; the first one it came across:

0 0

Answer

SELECTED ANSWER
replied on October 18, 2017

My mistake, I totally missed that at the top of the screenshot.

It looks like token is set to only take the first index in the collection (the #(1)# at the end).

Remove that and you should be good to go.

0 0

Replies

replied on October 16, 2017 Show version history

Looks like you're getting a warning in your Find Entry activities. What do you see in the Messages tab after you run the workflow?

Also, if you're using a multi-value token to collect the user inputs, then you need to wrap the conditional in a For Each Value loop so it runs on each value in the collection.

It seems like From vs To is an OR condition, not an AND/OR, so you want a Conditional Decision instead of a Conditional Parallel since each value can only be one or the other.

Any time you're dealing with collections, tables, etc., you need a For Each of some sort because that tells workflow to run the contained activities on each distinct value.

0 0
replied on October 18, 2017

Jason:

1) Yes, the Find Entry activity did not find the entry and that is fine.  It is told to look for the starting document.  If it is not there, then and only then go ahead and place the shortcut in the folder.

2) Multi-value token - it is in the loop, isn't it?  Okay, so here is what I see happening.  Maybe you can see what I'm not seeing (obviously there's something I'm not seeing): 

  • WF finds three filing choice values
  • For Each Value 
    • create a token to assign To or From
    • depending on To or From - complete these steps (find out if the starting entry is already in the target folder, if not put a shortcut in the target folder)
    •  

3) From vs To - yes, it is an either or condition for each of the multi-value tokens, however, for each token it might be one or the other so I need it to continue to keep checking.

4) Dealing with collections - need a For Each. yes, am I missing something in the design that has to do with this?

0 0
replied on October 18, 2017

For the problem with the For Each, see Jennifer's or my response in the other thread. As for the condition, with the loop you don't need a parallel. Although it could be either one overall, each iteration is going to be only one or the other so you only need a conditional decision.

0 0
replied on October 17, 2017

Why do you have it set up as a conditional parallel instead of a conditional decision?  As long as it is inside the for each loop, it will run only 1 value at a time so a conditional decision should work.

But yes, as Jason suggested, confirm that the conditional is inside the for each loop.

0 0
replied on October 18, 2017

Jennifer, this workflow was set up using a conditional decision and does work great that way.  In most cases, the user will be picking only one filing choice.  However, I recently came across a case where someone brought in a scan of a bunch of emails back and forth between two companies, all on the same topic.  In that case, there was in fact a reason to put a shortcut in the Correspondence\Received folders and in the Correspondence\Sent folders AND I could see that in some future cases a person may be sending correspondence to two groups of individuals.

So, I decided to see if I could get the workflow to account for all of those possibilities.  I was hoping it could see (as in the test example) three values, cycle through each of those values to see if it was a "to" or a "from" and place the shortcuts in each appropriate folder.

0 0
replied on October 18, 2017

Connie,

To account for multiple values, you'll still need a For Each Value to make it capable of iterating through them all. However, something worth noting is that the For Each will still work even if there is only one value because it would just do one iteration.

0 0
replied on October 18, 2017 Show version history

I have a For Each Value, so why is it not moving on to the next value after finishing with the first one?

0 0
replied on October 18, 2017

The image is small and I can't quite read it.  Can you show how your for each loop is set up?  It almost looks like you are only pulling the first value.  The image kind of looks like it ends in #(1)#.

0 0
SELECTED ANSWER
replied on October 18, 2017

My mistake, I totally missed that at the top of the screenshot.

It looks like token is set to only take the first index in the collection (the #(1)# at the end).

Remove that and you should be good to go.

0 0
replied on October 18, 2017

In all of the configurations I tried, I did try some choices with the indexes and some of them showed the #(1)# in the configuration, however, nothing worked.

0 0
replied on October 18, 2017

SUCCESS!  Thank you to both of you Jennifer and Jason!

It was the indexing option.  After posting the above, I noticed that I still had that on my latest attempts.  Once I change it back to no choices for the indexing, it worked!

0 0
replied on October 18, 2017 Show version history

Jennifer, I did also change back my activity to the Conditional Decision.  I think I chose the Conditional Parallel before I added the For Each Value.  Once that was added, like you both pointed out, I no longer needed the parallel configuration.

0 0
replied on October 18, 2017

On the Assign Token Values activity, you should also use the "For Each Current Value" token instead of using the RetrieveFieldValues token directly. The for each tokens will automatically give you the current index.

1 0
replied on October 18, 2017

Thank you for pointing that out, Jason.  I had noticed that this activity wasn't giving me the option for current value and wondered about that.  In checking it now after you've mentioned it, I see that it is there now (since I removed the indexing from the For Each Value configuration).

0 0
replied on October 18, 2017

Awesome! Sounds like everything should work for you now yes

0 0
replied on October 18, 2017

SUCCESS LOOKS LIKE THIS (Adding this for anyone else researching these posts for help with something they are doing):

and the configuration to achieve that was:

0 0
replied on October 18, 2017 Show version history

You may be wondering why you see the department indicator in the path of the Sent correspondence.  It's because we separate out the Sent correspondence between departments, but don't bother doing that with Received correspondence. 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.