action (switch)

Parent: action

Applies whentype = switch

Direct Properties:

PropertyTypeRequiredDefault ValueDetails
namestringYesdata type=string; maxLen=255
Enter a name for the task definition action.
typeenumYesdata type=string; lov=PLUGINS
Valid values: switch

Property Groups:

  • switch
  • compare
  • condition
  • source
  • execution
  • successMessage
  • error
  • advanced
  • serverSideCondition
  • config
  • comments
switch
PropertyTypeRequiredDefault ValueDetails
typeenumYestrueFalseCheckdata type=string; maxLen=4000; lov=STATIC
Valid values: case trueFalseCheck checkWorkflowVar if
switch {
  type: case
}
compare
PropertyTypeRequiredDefault ValueDetails
dataTypeenumYesvarchar2data type=string; maxLen=4000; lov=STATIC
Valid values: boolean timestampWithTimeZone timestamp timestampWithLocalTimeZone number varchar2
Applies whentype = CASE
compareTypeenumYessqlQuerydata type=string; maxLen=4000; lov=STATIC
Valid values: functionBody sqlQuery expression
Applies whentype = CASE
compareVarstringYesdata type=string; maxLen=4000; textCase=UPPER
Applies whentype = CHECK_WF_VARIABLE
compareSqlQuerystringYesdata type=string; maxLen=4000
Applies whentype = CASE and compare_type = SQL_QUERY
comparePlsqlExpressionstringYesdata type=string; maxLen=4000
Applies whentype = CASE and compare_type = EXPRESSION
comparePlsqlFunctionBodystringYesdata type=string; maxLen=4000
Applies whentype = CASE and compare_type = FUNCTION_BODY
compareLanguageenumYesplsqldata type=string; lov=STATIC
Valid values: plsql js-mle
Applies whentype = CASE and compare_type in (EXPRESSION)type = CASE and compare_type in (FUNCTION_BODY)
compare {
  dataType: boolean
  compareType: functionBody
  compareVar: value
  compareSqlQuery: value
  comparePlsqlExpression: value
  comparePlsqlFunctionBody: value
  compareLanguage: plsql
}
condition
PropertyTypeRequiredDefault ValueDetails
conditionTypeenumYesrowsReturneddata type=string; maxLen=4000; lov=STATIC
Valid values: workflowVarIsNotNull rowsReturned workflowVarNotEqualsValue workflowVarIsNull rowsNotReturned workflowVarEqualsValue expression functionBody
Applies whentype = TRUE_FALSE_CHECK
sqlQuerystringYesdata type=string; maxLen=4000
Applies whentype = TRUE_FALSE_CHECK and condition_type in (ROWS_RETURNED)type = TRUE_FALSE_CHECK and condition_type in (ROWS_NOT_RETURNED)
plsqlExpressionstringYesdata type=string; maxLen=4000
Applies whentype = TRUE_FALSE_CHECK and condition_type = EXPRESSION
languageenumYesplsqldata type=string; lov=STATIC
Valid values: plsql js-mle
Applies whentype = TRUE_FALSE_CHECK and condition_type in (EXPRESSION)type = TRUE_FALSE_CHECK and condition_type in (FUNCTION_BODY)
plsqlFunctionBodystringYesdata type=string; maxLen=4000
Applies whentype = TRUE_FALSE_CHECK and condition_type = FUNCTION_BODY
workflowVarstringYesdata type=string; maxLen=4000; textCase=UPPER
Applies whentype = TRUE_FALSE_CHECK and condition_type in (WF_VARIABLE_NULL)type = TRUE_FALSE_CHECK and condition_type in (WF_VARIABLE_NOT_NULL)type = TRUE_FALSE_CHECK and condition_type in (WF_VARIABLE_EQ_VAL)type = TRUE_FALSE_CHECK and condition_type in (WF_VARIABLE_NEQ_VAL)
valuestringYesdata type=string; maxLen=4000
Applies whentype = TRUE_FALSE_CHECK and condition_type in (WF_VARIABLE_EQ_VAL)type = TRUE_FALSE_CHECK and condition_type in (WF_VARIABLE_NEQ_VAL)
condition {
  conditionType: workflowVarIsNotNull
  sqlQuery: value
  plsqlExpression: value
  language: plsql
  plsqlFunctionBody: value
  workflowVar: value
  value: value
}
source
PropertyTypeRequiredDefault ValueDetails
locationenumYeslocalDatabasedata type=string; lov=STATIC
Valid values: localDatabase restEnabledSql
languageenumYesplsqldata type=string; lov=STATIC
Valid values: plsql javaScript-mle
Applies whenlocation = localDatabase
plsqlCodemultiline stringYesdata type=multiline string; maxLen=32767
Applies whenlocation = localDatabase and language = plsql
javaScriptCodemultiline stringYesdata type=multiline string; maxLen=32767
Applies whenlocation = localDatabase and language = javaScript-mle
remoteServerreferenceYesdata type=reference; lov=COMPONENT; references=restEnabledSqlDatabase
Applies whenlocation = restEnabledSql
plsqlCodemultiline stringYesdata type=multiline string; maxLen=32767
Applies whenlocation = restEnabledSql
Enter the PL/SQL code to be executed on the remote database.
source {
  location: localDatabase
  language: plsql
  plsqlCode: ```plsql
    value
  ```
  javaScriptCode: ```javascript-mle
    value
  ```
  remoteServer: @component
}
execution
PropertyTypeRequiredDefault ValueDetails
onEventenumYesclaimdata type=string; lov=STATIC
Valid values: claim complete setOutcome delegate updateComment updatePriority updateParameter release cancel create requestInformation submitInformation beforeExpire expire fail
outcomeenumNodata type=string; lov=STATIC
Valid values: approved rejected
Applies whenonEvent = complete and type = approval
outcomestringYesdata type=string; maxLen=255
Applies whenonEvent = setOutcome
beforeExpirationIntervalstringNodata type=string; maxLen=32767
Applies whenonEvent = beforeExpire
sequencenumberYesdata type=number; maxLen=22
execution {
  onEvent: claim
  outcome: value
  beforeExpirationInterval: value
  sequence: 42
}
successMessage
PropertyTypeRequiredDefault ValueDetails
successMessagemultiline stringNodata type=multiline string; maxLen=4000

Enter the success message for this process. If the process runs and does not generate an error, then this process success message displays in the notification section of the resulting page displayed. If you are branching to another page via a URL redirect, you may need to check the preserve success message attribute.

For multi row processes, the following substitution string can be used to get the number of records processed:

  • Insert: #MRI_COUNT#
  • Update: #MRU_COUNT#
  • Delete: #MRD_COUNT#

For the Send E-Mail process type the substitution string #TO# can be used to get the addressees of the e-mail.

Plug-ins can have other substitution strings as well. See Plug-in documentation for details.

successMessage {
  successMessage: ```
    value
  ```
}
error
PropertyTypeRequiredDefault ValueDetails
errorMessagemultiline stringNodata type=multiline string; maxLen=4000
Enter an error message to be written to the task history when the processing fails. Use #SQLERRM# as a placeholder for the actual ORA error message.
loggingenumYesnonedata type=string; lov=STATIC
Valid values: none success failure all
stopExecutionOnErrorbooleanYestruedata type=boolean
Enable when processing for the current task should stop on error. Subsequent actions will not be processed in this case and the task will go the ERRORED state.
error {
  errorMessage: ```
    value
  ```
  logging: none
  stopExecutionOnError: false
}
advanced
PropertyTypeRequiredDefault ValueDetails
staticIdstringYesdata type=string; maxLen=255
advanced {
  staticId: value
}
serverSideCondition
PropertyTypeRequiredDefault ValueDetails
typeenumNodata type=string; lov=STATIC
Valid values: rowsReturned noRowsReturned expression functionBody item=value item!=value itemIsNull itemIsNotNull itemIsZero itemIsNotZero itemIsNullOrZero itemIsNotNullAndNotZero itemContainsNoSpaces itemIsNumeric itemIsNotNumeric itemIsAlphanumeric itemIsInColonDelimitedList itemIsNotInColonDelimitedList textIsContainedInItem text=value text!=value textIsContainedInValue textIsNotContainedInValue never
sqlQuerymultiline stringYesdata type=multiline string; maxLen=4000
Applies whentype in (rowsReturned)type in (noRowsReturned)
languageenumYesplsqldata type=string; lov=STATIC
Valid values: sql plsql javaScript-mle
Applies whentype = expression
sqlExpressionmultiline stringYesdata type=multiline string; maxLen=4000
Applies whentype = expression and language = sql
plsqlExpressionmultiline stringYesdata type=multiline string; maxLen=4000
Applies whentype = expression and language = plsql
javaScriptExpressionmultiline stringYesdata type=multiline string; maxLen=4000
Applies whentype = expression and language = javaScript-mle
languageenumYesplsqldata type=string; lov=STATIC
Valid values: plsql javaScript-mle
Applies whentype = functionBody
plsqlFunctionBodymultiline stringYesdata type=multiline string; maxLen=4000
Applies whentype = functionBody and language = plsql
javaScriptFunctionBodymultiline stringYesdata type=multiline string; maxLen=4000
Applies whentype = functionBody and language = javaScript-mle
itemstringYesdata type=string; maxLen=4000; textCase=UPPER
Applies whentype in (item=value)type in (item!=value)type in (VALUE_OF_ITEM_IN_COND_1_EQ_COND_2)type in (VALUE_OF_ITEM_IN_COND_1_NOT_EQ_COND_2)type in (itemIsNull)type in (itemIsNotNull)type in (itemIsZero)type in (itemIsNotZero)type in (itemIsNullOrZero)type in (itemIsNotNullAndNotZero)type in (itemContainsNoSpaces)type in (itemIsNumeric)type in (itemIsNotNumeric)type in (itemIsAlphanumeric)type in (itemIsInColonDelimitedList)type in (itemIsNotInColonDelimitedList)
textstringYesdata type=string; maxLen=4000
Applies whentype in (textIsContainedInItem)type in (textIsContainedInValue)type in (textIsNotContainedInValue)type in (text=value)type in (text!=value)
valuestringYesdata type=string; maxLen=4000
Applies whentype in (item=value)type in (item!=value)type in (VALUE_OF_ITEM_IN_COND_1_EQ_COND_2)type in (VALUE_OF_ITEM_IN_COND_1_NOT_EQ_COND_2)
listarray of stringsYesdata type=string; maxLen=4000
Applies whentype in (itemIsInColonDelimitedList)type in (itemIsNotInColonDelimitedList)
itemstringYesdata type=string; maxLen=4000; textCase=UPPER
Applies whentype = textIsContainedInItem
valuestringYesdata type=string; maxLen=4000
Applies whentype in (textIsContainedInValue)type in (textIsNotContainedInValue)type in (text=value)type in (text!=value)
serverSideCondition {
  type: rowsReturned
  sqlQuery: ```sql
    value
  ```
  language: sql
  sqlExpression: ```sql
    value
  ```
  plsqlExpression: ```plsql
    value
  ```
  javaScriptExpression: ```javascript-mle
    value
  ```
  plsqlFunctionBody: ```plsql
    value
  ```
  javaScriptFunctionBody: ```javascript-mle
    value
  ```
  item: value
  text: value
  value: value
  list: [
    value
    value
  ]
}
config
PropertyTypeRequiredDefault ValueDetails
buildOptionreferenceNodata type=reference; lov=COMPONENT; references=buildOption
config {
  buildOption: @component
}
comments
PropertyTypeRequiredDefault ValueDetails
commentsmultiline stringNodata type=multiline string; maxLen=4000
comments {
  comments: ```
    value
  ```
}

APEXlang Example

action sample (
    name: value
    type: switch
    switch {
        type: case
    }
    compare {
        dataType: boolean
        compareType: functionBody
        compareVar: value
        compareSqlQuery: value
        comparePlsqlExpression: value
        comparePlsqlFunctionBody: value
        compareLanguage: plsql
    }
    condition {
        conditionType: workflowVarIsNotNull
        sqlQuery: value
        plsqlExpression: value
        language: plsql
        plsqlFunctionBody: value
        workflowVar: value
        value: value
    }
    source {
        location: localDatabase
        language: plsql
        plsqlCode: ```plsql
          value
        ```
        javaScriptCode: ```javascript-mle
          value
        ```
        remoteServer: @component
    }
    execution {
        onEvent: claim
        outcome: value
        beforeExpirationInterval: value
        sequence: 42
    }
    successMessage {
        successMessage: ```
          value
        ```
    }
    error {
        errorMessage: ```
          value
        ```
        logging: none
        stopExecutionOnError: false
    }
    advanced {
        staticId: value
    }
    serverSideCondition {
        type: rowsReturned
        sqlQuery: ```sql
          value
        ```
        language: sql
        sqlExpression: ```sql
          value
        ```
        plsqlExpression: ```plsql
          value
        ```
        javaScriptExpression: ```javascript-mle
          value
        ```
        plsqlFunctionBody: ```plsql
          value
        ```
        javaScriptFunctionBody: ```javascript-mle
          value
        ```
        item: value
        text: value
        value: value
        list: [
          value
          value
        ]
    }
    config {
        buildOption: @component
    }
    comments {
        comments: ```
          value
        ```
    }
)