on 2023 Feb 15 7:09 AM
Hi
Is it possible to define an input an optional to Automation artifact? I have currently declared few inputs to the Automation, which will be given by a Form (built using in built form editor) . e.g.

We have few more inputs to this Automation. On the User Form side, not all the fields are mandatory. Some are optional. So when the user skips the values for these optional fields, the automation fails since the fields are not added in the input context to the Automation at runtime.
e.g.

So if the fields are optional on the User Form, and the values are not entered - then these are not added in the context and then the Automation fails.
Is there a work around to define optional inputs to Automation?
Thanks
Sandip
Request clarification before answering.
I imagine you could use a decision table, using a custom data type with all of your inputs. That data type would be the input and output of the decision. And then in the output you would set some sort of default. Inside the automation you would have to check for the defaults, depending on what you wanted to do.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Did you ever find a solution?
I was able to do this:
HTH
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi guys,
Is there in the meantime a "more comfortable" solution possible?
I have the the same problem. I want to make some fields as optional in the form. But when to start the automation all fields need to have a value.
If no better solution is present, could you please explain the decision table? I tried it my way (without using decision tables before) and it says that it also needs a value to start decision table (input is empty but defined in process).
Best Regards
Mathias
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I'm not exactly sure what you are asking, but yes, a Decision activity needs to have an input. Generally, you just define something, bind something to that input, and then write a condition true = true
I imagine soon there will be something like an expression editor where you will no longer need Decisions for this purpose.
Hi @Dan_Wroblewski,
I have a form with two input fields. The "Feld Nr. 2" is optional.
I want to change the value in the decision table. So when the input for that field is "empty" then the output of the decision table should be some default value like "000" or something. I can work with that value in the automation then.
But the input for the decision table is also mandatory. So when the field in the form is not filled, it is crashing.
How to solve this?
Best Regards,
Mathias
if anyone wants to replicate the issue, I have created a sample project which replicates this issue. This is hosted on the github
https://github.com/theblock-dev/SAP-SPA-Error
Download the mtar and import it in SPA lobby. Then run the process after deploying.
On the Start form, pls skip the optional fields. Do not enter any values for these. And Submit.
Thanks
Sandip
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi
Try using Condition Control to handle the optional attribute on Automation Side. Essentially use it only when it set. https://help.sap.com/docs/IRPA/8e71b41b9ea043c8bccee01a10d6ba72/7109ddfba0cb497e809b956e0b895835.htm...
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Raghuraman
Thanks for your reply.
Well, using Condition Control is not applicable. It is the first step of the Automation itself. The User Form will supply few fields to the Automation artifact, if some fields are missing - triggering of the first step of Automation itself is failing.
This error is easy to replicate. Create an Automation with few inputs, create a Form with same fields but optional. And try to trigger the Automation using the Form.
One solution would be - if the Automation artifact allows declaring optional inputs. But I did not find any option to do that.
Thanks
Sandip
| User | Count |
|---|---|
| 6 | |
| 5 | |
| 4 | |
| 3 | |
| 3 | |
| 3 | |
| 3 | |
| 2 | |
| 2 | |
| 2 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.