Get Expression rule by name

Hi there,

 

does anybody know whether it possible to get an expression rule by its name?

Problem context:
In my application (software request), I want to maintain software.
Some software needs to be approved before installation.
I am thinking about designing the (sometimes complex) rules for identifying the approval user groups in terms of expression rules.
(Doing this with decision tables is not possible since I need a CDT as rule input)
These rules would then be referenced by name as an attribute of the software CDT.
Within the software request process, I then want to get the referenced expression rule and execute it to get the approval group to forward the approval task to.

  Discussion posts and replies are publicly visible

Parents
  • I have accomplished something similar to this in the past by utilizing Appian's externalize() and internalize() functions.

    Steps: 

    1. Use externalize(rule!someExpression)
      1. Do not put the parenthesis for your expression in this function
    2. Store this string in your CDT to reference later.  For this example, I would store it in ri!softwareCDT.externalizedString
    3. To call this expression: internalize(ri!softwareCDT.externalizedString)(input1: "ABC", input2: "XYZ")

    This should execute the rule reference you have stored as a string in your CDT.

    There may be some extra challenges you face, but this is the basic concept.

Reply
  • I have accomplished something similar to this in the past by utilizing Appian's externalize() and internalize() functions.

    Steps: 

    1. Use externalize(rule!someExpression)
      1. Do not put the parenthesis for your expression in this function
    2. Store this string in your CDT to reference later.  For this example, I would store it in ri!softwareCDT.externalizedString
    3. To call this expression: internalize(ri!softwareCDT.externalizedString)(input1: "ABC", input2: "XYZ")

    This should execute the rule reference you have stored as a string in your CDT.

    There may be some extra challenges you face, but this is the basic concept.

Children