Parameter from Dropdown List

Support/help with CloverETL (4.9) and CloverDX (5.0 or newer) implementation problems

Nismon8er
Posts: 10
Joined: Thu Apr 01, 2021 7:51 pm

Parameter from Dropdown List

Postby Nismon8er » Fri May 28, 2021 4:34 pm

Hello,

Is there a way to have a dropdown list of possible parameter values in the editor? I don't want there to be the possibility of people entering the wrong values when defining a specific parameter.

Thank you

habrzettlovah
Posts: 6
Joined: Tue Jun 01, 2021 9:59 am

Re: Parameter from Dropdown List

Postby habrzettlovah » Tue Jun 01, 2021 10:05 am

Hello,

If you create a parameter with the Editor Type of “Enumeration”, you can then specify the allowed values and users will then be able to pick them from the list. To do this please follow the steps below:

1. Open the Parameter editor and create a new parameter/edit an existing one and click on the three dots next to the Editor Type value.
2. In the Simple type section select the “Enumeration” type.
3. In the Configuration property section > Values field, enter all the allowed values separated by a semicolon. If you do not want to allow users to enter different values than specified uncheck the Allow Custom Value check box.
---
Hana Habrzettlova
CloverCARE Support
CloverDX

Visit us online at http://www.cloverdx.com

Nismon8er
Posts: 10
Joined: Thu Apr 01, 2021 7:51 pm

Re: Parameter from Dropdown List

Postby Nismon8er » Tue Jun 01, 2021 4:17 pm

habrzettlovah wrote:Hello,

If you create a parameter with the Editor Type of “Enumeration”, you can then specify the allowed values and users will then be able to pick them from the list. To do this please follow the steps below:

1. Open the Parameter editor and create a new parameter/edit an existing one and click on the three dots next to the Editor Type value.
2. In the Simple type section select the “Enumeration” type.
3. In the Configuration property section > Values field, enter all the allowed values separated by a semicolon. If you do not want to allow users to enter different values than specified uncheck the Allow Custom Value check box.


This works perfectly thank you.

One more thing perhaps you can help me out with. When setting up the RunGraph Component, is there a way I can setup the "Graph parameters to pass" and have it update all the components that need it. Like for example I have 30 RunGraph components, that all are using the same parameters. If I make a new parameter required, I am going to have to edit the parameters of all 30 components. Is there a way to avoid that to where I can just edit it in one location and they all see the newly updated params?

habrzettlovah
Posts: 6
Joined: Tue Jun 01, 2021 9:59 am

Re: Parameter from Dropdown List

Postby habrzettlovah » Thu Jun 03, 2021 12:28 pm

Hello,

An option here would be to use a recursive parameter in the Graph parameters to pass field in the RunGraph component instead of passing individual parameters as a list. To create a recursive parameter please follow the steps below:

1. Create a new parameter in the graph where you have the RunGraph component. The parameter type needs to be String and in the Value field enter the names of all the parameters that need to be passed to the child graph, separated by semicolons.
2. Update the RunGraph component and delete the original list of parameters in the Graph parameters to pass field and replace it by the name of the recursive parameter in the form of a reference, e.g.: ${NAME_OF_RECURSIVE_PARAMETER}.

By using this reference CloverDX will pass the list of specified parameters to the graphs. Even though it will require a manual update of all your RunGraph components to switch the list of parameters to the recursive one, once you do this and there is a need to add a new parameter in the future, the parameter will only need to be added to the recursive parameter and it will be then automatically distributed to all components that use it.
I have attached example graphs to demonstrate how to use the recursive parameter in the Graph parameters to pass field.
Attachments
TestGraphForRunGraph.grf
(2.49 KiB) Downloaded 126 times
RunGraphComponent.grf
(1016 Bytes) Downloaded 126 times
---
Hana Habrzettlova
CloverCARE Support
CloverDX

Visit us online at http://www.cloverdx.com

Nismon8er
Posts: 10
Joined: Thu Apr 01, 2021 7:51 pm

Re: Parameter from Dropdown List

Postby Nismon8er » Thu Jun 10, 2021 4:18 pm

habrzettlovah wrote:Hello,

If you create a parameter with the Editor Type of “Enumeration”, you can then specify the allowed values and users will then be able to pick them from the list. To do this please follow the steps below:

1. Open the Parameter editor and create a new parameter/edit an existing one and click on the three dots next to the Editor Type value.
2. In the Simple type section select the “Enumeration” type.
3. In the Configuration property section > Values field, enter all the allowed values separated by a semicolon. If you do not want to allow users to enter different values than specified uncheck the Allow Custom Value check box.


Also Sorry I forgot to mention this in the post above. Is there a way to enable/disable components not based on boolean params but based on one of the selections in the dropdown that I have just created. So for example if I have a drop down with values A;B;C; I only want to enable my component if the selection for that param is B, if its A or C then disabled.

Thank you

habrzettlovah
Posts: 6
Joined: Tue Jun 01, 2021 9:59 am

Re: Parameter from Dropdown List

Postby habrzettlovah » Fri Jun 11, 2021 2:17 pm

Hello,

The “Enable with condition” logic requires a Boolean value, however, there is a way to achieve what you need by using a dynamic parameter. You would need to create a new parameter that would be used to set the enabled/disabled value based on your conditions.

I have attached an updated graph for your review to illustrate how to achieve this. In my example, I created a parameter called “ENABLED”. The parameter is a dynamic parameter that looks at what is passed to another parameter called “DAY”. If the value in the DAY parameter is “Monday”, it enables the FastSort component; otherwise, it disables it.

I hope this helps!
Attachments
DynamicParameterEnableComponent.grf
(3.02 KiB) Downloaded 125 times
---
Hana Habrzettlova
CloverCARE Support
CloverDX

Visit us online at http://www.cloverdx.com


cron