Next Step Expression - Drill Down to be Field Specific
Is it possible, in the Data Review process step, to have a Next Step Expression that targets one specific field being flagged/having a data error? I have seen other Xchange questions that ask this, but it looks like it’s related to the Should Submit Expression.
Background:
If a PO_NUMBER exists on an invoice, I flag that field. In Data Review, if it’s a valid PO number we would leave it as is and click Complete Task. We would want any invoice with a PO Number to spawn to another batch process. Otherwise we would send it to document export.
Currently I have it set up in Data Review:
If the batch has a flagged item go to spawn batch, otherwise go to document export.
I was wondering if we could drill down further and only let it go to the spawn batch if that flagged item is the PO_NUMBER field.
Best Answer
-
Bradley Posts: 94 ✭✭✭The desired request is too complicated for multiple reasons for a Next Step Expression. I've traveled this path and it is a dead-end. A custom batch activity should be created and placed immediately after Data Review.
1. The logic for the Next Step Expression only runs at the scope specified on the Batch Step. If the scope is set to batch, you can't loop through the documents and check their PO Number field. Source code will ignore any loop you try to pass into the Next Step Expression.
2. In regard to #1, changing the scope to the level where the indexed documents exist will completely change how Data Review "feels" because you will be processing each document independently of the batch. If multiple people are involved in processing, everyone would be touching the same batch. This can easily create a complicated workflow where no one knows who is working which batch. And if you are trying to audit the batch for an issue that might be user related, you'll have diverging paths to consider when looking for the issue that required the audit. If you follow the approach of 1 person to 1 batch, there is ownership there that is much easy to track and count. Depending on the complexity of the documents and processing, you may lose some control over how the batch is processed due to multiple people using some variance in conditional decision making based on what they see on the screen.
3. Using a custom batch activity after Data Review will allow you to specify one or more conditions for the documents to determine the next step.
I'd go the route of creating a batch activity.
You can also submit a request for enhancement and the developers can create a more elegant solution but you will probably want a temporary solution available until that new feature is developed and released.5
Answers
However, the spawn step itself doesn't have the flexibility you would need to only spawn out documents with an issue on the one field in question. Would require a custom activity. I also think I may have heard rumblings of an update coming down the road that adds some additional flexibility to the spawn activity, but not sure when it is going to be released and what all it would include.
Product Manager
mharrison@bisok.com