In this tutorial you will learn how to use the LiveReport Selected Rows input type to use subset of rows in a parameter.
The use case is the following: recalculate all the models available in the current LiveReport for selected rows.
Topics covered:
Set LiveDesign Context
componentGet LiveDesign Models
componentRun LiveDesign Models
component- LiveReport Selected Rows input type
Create protocol in Pipeline Pilot
-
Create the new protocol
- Open the Pipeline Pilot client.
- Create a new protocol.
- Save it somewhere in
Protocols
as "Run Models for Selected Rows". Your personal space is not accessible from the gadget.
-
Get the current LiveReport ID
- Add the
Set LiveDesign Context
component to your protocol.- This component extracts the active LiveReport ID when the protocol is triggered from the gadget and set it into the global property activeLiveReportID.
- Add the
-
Get the list of models available in the current LiveReport
- Add the
Get LiveDesign Models
component to your protocol. - Set the
Search Type
parameter to "By LiveReports". - Set the
LiveReport IDs
parameter to "$(activeLiveReportID)".
- Add the
-
Run the models for selected rows
- Add the
Run LiveDesign Models
component to your protocol. - Set the
LiveReport ID
parameter to "$(activeLiveReportID)". - Set the
Model IDs
parameter to the data property "id".- To do so, right-click on the parameter name, then click on "Initialize Using > Data Property". Set the text field to "id" and check "Reinitialize for each data".
- Set the
Run For Rows
parameter to "All rows from selection". - Promote the
Row IDs
parameter to the protocol level and rename it "Calculate Rows".
- Add the
Test protocol in Pipeline Pilot
-
Connect to LiveDesign
- Add the
Set Livedesign Connection Details
component to your protocol. - Fill in the
LiveDesign Username
andLiveDesign Password
parameters with your LiveDesign credentials. - This is only for testing in Pipeline Pilot. After the test you should either clear these parameters or remove the component.
- Add the
-
Set the active LiveReport context
- Fill the
Active LiveReport Default Value
parameter of theSet LiveDesign Context
component with the identifier of a LiveReport which you can use for testing. - This is only for testing in Pipeline Pilot. It will apply the set value to the global property activeLiveReportID.
- Fill the
-
Fill in the parameters of the protocol
- Fill in the
Calculate Rows
parameter of the protocol with the identifiers of rows (from ID column) that you want to recalculate for testing.
- Fill in the
-
Run the protocol
- You can set the Design Mode to check the content of each record.
- The number of records passing through the components should be the number of models available in the LiveReport used for testing.
-
Check the LiveReport used for testing in LiveDesign
- The columns coming from models should have been recalculated for the rows set in the
Calculate Rows
parameter.
- The columns coming from models should have been recalculated for the rows set in the
Register protocol in LiveDesign
-
Open the registration menu
- Open LiveDesign and the gadget.
- Click on the icon in the gadget menu. You can see it only if you are gadget administrator.
-
Select the protocol
- Browse the tree of Pipeline Pilot protocols.
- Select the previously created "Run Models for Selected Rows" protocol.
-
Define the inputs
- Set the type of the
Calculate Rows
parameter to "LiveReport Selected Rows". - Click on "Next".
- Set the type of the
-
Create the menu item
- Select the location of the protocol in the menu. If needed you can create another folder or subfolder.
- If needed set the draft mode to hide the protocol from non-administrator users.
- Click on "Add".
Test protocol in LiveDesign
- Select the newly registered protocol "Run Models for Selected Rows" protocol in the gadget menu. If it has been saved in draft mode, the name of the protocol will be in italic and an icon will be in front of it.
- Select rows in the LiveReport. The field
Calculate Rows
will be automatically updated in the form. - Click on "Submit".
- You should see all the models of the LiveReport being recalculated for the selected rows.