MicroStrategy ONE
Using Parameters for Processes
While all the necessary configuration information can be provided for each process, some scenarios require that the details about the process be provided when the workflow is executed. This can be required for the scenarios listed below:
- Storing user credentials within System Manager introduces a security risk.
- Configuration information is not known until or during the actual configuration.
To provide a flexible solution to these types of problems, System Manager lets you define parameters as part of your workflow. These parameters can be used to define configuration information for the processes supported by System Manager. The values of these parameters can be provided as part of the workflow, as part of a parameters file to execute the workflow, and as input from the user performing the workflow from the command line.
Creating Parameters for a Workflow
A workflow has one set of parameters that is shared for all processes. The parameters that are created for a workflow can be used in any configuration task that can accept parameters as values in a process. Parameters can also be used in decisions in a workflow.
The steps below show you how to create parameters for a workflow.
To Create Parameters for a Workflow
This procedure assumes you are creating new parameters for a workflow. For information on importing parameters for a workflow, see Importing Parameters into a Workflow.
- Open System Manager.
- To open System Manager in a Windows environment:
- Start > All Programs > MicroStrategy Products > System Manager.
- To open System Manager in a UNIX or Linux environment:
- In a Linux console window, browse to
HOME_PATH
whereHOME_PATH
is the specified home directory during installation. - Browse to the folder
bin
. -
Type
mstrsysmgrw
, and then press Enter.The System Manager home page is displayed.
- Expand the Properties and parameters pane on the right side of System Manager, and click Parameters near the bottom.
- Click Add new parameter (displayed as a green plus symbol) to create a new parameter. Name and Value fields are displayed.
- Type the following information:
- Name: The name for the parameter. This is the name that is used to identify the parameter in a process or decision within the workflow.
- Value: The value that is used in place of the parameter when the workflow is executed. This works as the default value for the parameter if no value for the parameter is given from the command line when the workflow is executed. For information on the precedence of providing values for parameters, see Providing Parameter Values during Deployment of a Workflow.
If the parameter provides sensitive information such as user passwords, you can leave the value blank. However, be aware that these parameters must be provided a value when the workflow is executed.
- Confidential: Select the check box to turn off any logging and feedback information for parameter values that are updated by a process in your workflow (defined as an output parameter of a process). For example, if you save the result of a SQL execution to a parameter, this result is hidden from any System Manager logs. If the parameter value for a confidential parameter has to be shown in the feedback console, it is displayed as asterisks instead of the actual value. For information on the feedback console, see Using System Manager to Test and Deploy a Workflow.
- Once a parameter is created in a workflow, you can use it in a workflow, as described in Using Parameters in a Workflow. You can also use the Update Parameters process (see Performing System Processes) to update the value of a parameter during the deployment of a workflow.
Importing Parameters into a Workflow
You can import parameters into a workflow that have been saved as a parameters response file. This lets you update the values for your workflow.
When parameters are imported into a workflow, any existing parameters are updated with the values included in the parameters file. Parameters can only be updated when importing a parameters file. This means that if a parameter does not already exist in a workflow, it is not created when importing the parameters file.
Additionally, if parameters are in the workflow that are not defined in the parameters file, the value for the parameters is not updated during the import process.
The workflow you are importing parameters for already has parameters defined for it. Only these parameters can be updated by importing a parameters file.
To Import Parameters into a Workflow
- Open System Manager.
- To open System Manager in a Windows environment:
- Start > All Programs > MicroStrategy Products > System Manager.
- To open System Manager in a UNIX or Linux environment:
- In a Linux console window, browse to
HOME_PATH
whereHOME_PATH
is the specified home directory during installation. - Browse to the folder
bin
. - Type
mstrsysmgrw
, and then press Enter.The System Manager home page is displayed.
- Expand the Properties and parameters pane on the right side of System Manager, and click Parameters near the bottom.
- From the Workflow menu, select Import Parameter File.
- Select the parameters file to import and click Open. You are returned to System Manager and the parameters are updated accordingly. If the changes are not what you expected, you can click Clear to undo all the parameter updates.
Exporting Parameters to a File
You can export the parameters in a workflow to a file. This file can serve various purposes:
- You can import parameters into other workflows.
- You can modify the parameter file and apply updates to the original workflow.
- You can modify the parameter file and include it during execution to make changes just before execution.
- You can modify the parameter file to include comments, which can provide additional information on the parameters and their values. To include a comment in a parameters file you can use the characters
//
or#
to denote a line in the parameters file as a comment. Any line that begins with either//
or#
is ignored when using the parameters file with System Manager.
The steps below show you how to export the parameters of a workflow to a file.
To Export Parameters of a Workflow to a File
- Open System Manager.
- To open System Manager in a Windows environment:
- Start > All Programs > MicroStrategy Products > System Manager.
- To open System Manager in a UNIX or Linux environment:
- In a Linux console window, browse to
HOME_PATH
whereHOME_PATH
is the specified home directory during installation. - Browse to the folder
bin
. -
Type
mstrsysmgrw
, and then press Enter.The System Manager home page is displayed.
- From the Workflow menu, select Export Parameter File.
- In the File name field, type a name for the parameters file.
- Click Save.
Using Parameters in a Workflow
Parameters can be used in processes or decisions of a workflow to provide flexibility as to when the information is provided.
Parameters can be included in any option that takes some type of text or numeric data as input. For example, a Password field can take a parameter that supplies a password to access the task or system resource for a process. However, check boxes and any other options that do not accept text or numeric data cannot use parameters.
To use a parameter in a process or decision, you must use the following syntax:
${
ParameterName}
In the syntax listed above, ParameterName is the name of the parameter. During execution, this is replaced with the value for the parameter.
The values for parameters can be provided in a few different ways. For information on how parameter values can be provided and the precedence of each option, see Providing Parameter Values during Deployment of a Workflow below.
Providing Parameter Values during Deployment of a Workflow
The value for a parameter can be provided in the following ways:
- When defining the parameters for the workflow. These values act as the default value of the parameter.
- In a parameters file. This file can be used during the execution of a workflow to provide updated values for the parameters.
- From the command line during execution of a workflow. This lets the user executing the process provide sensitive information such as user passwords on the command line rather than saving them in a workflow.
- You can also use the Update Parameters process (see Performing System Processes) to update the value of a parameter during the deployment of a workflow.
When a workflow is executed, parameters are replaced with their respective values, as described below:
- If the value for a parameter is provided from the command line during execution, this value is used. Any values for the parameter provided in a parameters file or default values provided in the workflow are ignored.
- If the value for a parameter is not provided from the command line during execution, but a value for the parameter is provided in a parameters file, the value from the parameters file is used. The default value provided in the workflow is ignored.
- If the value for a parameter is not provided in a parameters file or from the command line during execution, the default value provided when defining a parameter in a workflow is used.
The image below summarizes how the value of a parameter is determined when executing a workflow: