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

Question

Question

Consolidating data collected from multiple entries in a Workflow

asked on November 8, 2017

Is there a way to group the data collected by a Laserfiche process so it can be presented (either in an email or as some kind of electronic doc) collectively vs individually?

I have a Workflow that finds entries in a given folder, retrieves metadata field values from those entries, and has a conditional option to email a coworker with the data found during the metadata retrieval step (see first attachment, first conditional branch).  This works great, except that each email contains data from one entry.  This means that if there are 30 entries that meet the condition when the workflow runs, my coworker gets 30 separate emails; see second attachment for an example of what these emails look like. Rather than receive individual emails, is there a way I can gather all the data so my coworker gets one email (or there is one document) that contains the data in a consolidated form from the all the applicable entries? See third attachment for an example of what I'd like it to look like.

The data doesn't have to be presented in an email.  If I could create a doc and then forward it, that would work as well.  I've tried the Custom Query tool and had the data go into an SQL table as it is collected, and that works fine, but I cannot find a way to pull the data back out of that table via a Workflow so I can automate how my coworker receives it.  Final attachment is what my SQL table looks like.

I am not a programmer, so while I would be willing to try something new, I'd need a little direction if there is any "scripting" involved.

Thank you!!

 

0 0

Answer

SELECTED ANSWER
replied on November 9, 2017

Probably the easiest way to do that is to add a "------" (or similar) value in your Assign Tokens when you add each set of values. It won't be a space, but it would be a delimiter value after each group.

When you get a bit of free time, I encourage you to take a look at the Update Word Document activity. You can do fancier formatting with Word, like bold only the names or conditionally add color to some of the values.

1 0

Replies

replied on November 8, 2017 Show version history

Hi Jane,

You could try something like this:

Create a multi-value token to contain your metadata values with an "Assign Token Values" activity. Name the token"metadata".

In the left-most branch of your workflow (or possibly right after entering the "For" loop, I can't say exactly), drop another "Assign Token Values" activity and modify the %(metadata) token, similar to what you see in the screenshot.

Finally, move the "Email" activity outside the loop, since the loop will need to complete in order to retrieve all metadata values from all entries. Drop your %(metadata) token into the appropriate area of the email body:

I hope this helps! Happy to clarify if you have any questions.

~Rob

2 0
replied on November 8, 2017 Show version history

Hi Rob –

I added the two “Assign Token Values” tools.  Here’s the first one:

I left the “Values” area blank.

Here’s the second one:

 

I added the token in my e-mail:

 

Published the workflow and ran it (email is outside of the “For Each Entry” area as you specified).  Here are the results (note – this is a test version of the workflow so I took out the conditions and just had everything feed directly into an email)

Unfortunately, here’s what my e-mail looks like:

When I look at the work flow results, it appears that the metadata is gathered correctly:

Round, Alice
 Associate of General Studies (AGS/5600/HC) - Special Admissions programs
NONE/NOT APPLICABLE

Ramirez, Kesia
Criminal Justice (AAS/5500/AS)
NONE/NOT APPLICABLE

Tsunenaga, Kenneth
Automotive Technology (AAS/5306/EL)
Crabill, Jeff
crabilj@linnbenton.edu
Beaird, Jessica
English Emphasis (AS/1501/AS)
NONE/NOT APPLICABLE

But it's not going into the email.  Am I missing something here?  (Sooo close!!)

0 0
replied on November 8, 2017

Made a tweak in the email, but now all I'm seeing is this vs all the records.

Here is where I grabbed the token from:

there isn't an option to select a token from the "Update metadata token" activity.

0 0
replied on November 8, 2017

The first one was because your token syntax was incorrect (using brackets instead of parentheses).

What you're running into now is that Workflow will use the first value from a multi-value field in single-value inputs (the email body is a giant single-value text box). You can get the rest of the values, but you have to specify how you want them delimited.

So, in the email body, right-click on the %(metadata) token and choose "Token Editor". In the dialog that opens, you should see an option for indexing.

2 0
replied on November 9, 2017

If you index the token like Miruna suggests, you should be good to go.

To clarify: when using the "Assign Token Values" activity to create and then subsequently modify a token, you will refer to the activity in which the token was created when using it elsewhere in the workflow.

2 0
replied on November 9, 2017

This is fantastic.  Seriously.  Just some final questions - is there a way to get the entries to be spaced apart?  See my sample email:

I'd love each entry (which ends with the email hyperlink) to be separated by a space or 2nd link break.  It looks like I could do a workaround on that by pulling in a field that is always blank (to replicate what happened in the record with"NONE/NOT APPLICABLE" - the next field had no data so it looks/acts like a blank line), but is there a way to format an extra "return" at the end of an entry?  Or does the formatting have to apply to every line of data?

Thank you SO much, this will be an incredible help for my process.

0 0
SELECTED ANSWER
replied on November 9, 2017

Probably the easiest way to do that is to add a "------" (or similar) value in your Assign Tokens when you add each set of values. It won't be a space, but it would be a delimiter value after each group.

When you get a bit of free time, I encourage you to take a look at the Update Word Document activity. You can do fancier formatting with Word, like bold only the names or conditionally add color to some of the values.

1 0
replied on November 9, 2017

I found I could actually add value fields that are blank - nice!

I will investigate the Update Word Document tool as well.  There's not much documentation on it, so I was a little stymied by what to do with the "Source" area.  

Thank you SO much for all the assistance with this.  You've been an enormous help in streamlining my process.  

1 0
replied on November 9, 2017

Good--that's what I was trying to point out with my arrow/text in an early reply! smiley

2 0
replied on November 9, 2017

You have been a fantastic help.  Thank you so much!!  Really appreciate it.

0 0
replied on November 9, 2017

My pleasure!

0 0
replied on November 8, 2017

Have you looked at the Update Word Document activity? You could merge the data from your SQL table into it. Then you can send the contents of the document as your email. It wouldn't require scripting, let us know if you want to try it on your own first or need a bit more direction.

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

Sign in to reply to this post.