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

Question

Question

Workflow - Why do you have to find entries to create a link to them, if you already have them in a collection?

asked on July 22, 2018

Why do you have to do this in workflow to link search results. This workflow is running excessively for every entry submitted by forms until a feature is added to link when saving to repository*. So I don't want unnecessary work.

What I am looking to do is this

CreateLinks(startingEntry,searchResults);

OR

foreach (Entry doc in searchResults)
{
  CreateLink(startingEntry,doc);
}

But what I am having to do is this

foreach (Entry doc in searchResults)
{
  Entry copy = new Entry(doc.ID)
  CreateLink(startingEntry,copy);
}

*The forms instance ID will not pass to workflow when calling directly (it is hidden in the list of variables and the Input Parameters are missing in the service task pane) preventing the ability for forms to inform workflow it is finished creating all documents when there are multiple save to repository tasks, so this workflow has to run on Entry Created by Forms and overload the links.

0 0

Replies

replied on July 23, 2018

For Each Entry's current entry is available in the Target Entry section of Create Link. Find Entry is not necessary.

The search's output entries are also available as target entries. For Each Entry is not needed in the scenario above to link the starting entry to a group of entries from a repository search.

However, if this workflow is running on entries created by Forms, you probably don't need to run a search. Maybe you can describe what you're trying to accomplish in more detail so we can propose a solution?

 

0 0
replied on July 23, 2018

Create Links only seems to work with a Find Entry activity. If you use any other object, like Current_Entry or Search_Results you get an error that the entry has an invalid connection profile. I do not know what it means to have an invalid connection profile for an object that has no associated explicit connection profile.

I have a forms process that saves multiple forms, and I would like to attach them, but forms only has an attachment option for uploads, not other forms.

The only method I can think of to attach, is to save the unique instance ID with each entry as a field value, then find and search for associated entries and link.

I tried calling workflow from forms but the instance ID does not show up as a variable, none of the system variables are showing in retrieve business process variables. Also when calling the workflow, I am unable to access the Input parameters to specify the instance ID.

This left me with only one option, run a workflow on Entry Created by Forms, which causes the workflow to run more times than necessary.

0 0
replied on July 23, 2018

You should definitely be able to target the Search Entry Output Entries object so you do not have to iterate through each.

Are you using multiple connections in your workflow that may be confusing it?

1 0
replied on July 23, 2018

Ok it finally worked. I found that I had to create a new workflow and set the connection profile before adding any activities to the canvas. If you add an activity, then set the connection profile it locks the link activity to only Find Entry activities.

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

Sign in to reply to this post.