Upload
subash249347
View
218
Download
0
Embed Size (px)
Citation preview
8/6/2019 Create Parameter is Ed Slicer
http://slidepdf.com/reader/full/create-parameter-is-ed-slicer 1/7
Cognos 8 Tip – Creating a Parameterized SlicerBy Nanci Forgeron, Education Specialist, Education Services, Cognos, Toronto, Canada
Here is a very neat tip that will enable a report that uses a slicer, created in Report Studio, to
be defined via a parameter applied to the slicer member set. This procedure uses the Great
Outdoors Company package and creates the slicer for the Product Line level.
1. Build a cross tab report with "Year level" as the column, "Order Method1" as the row
and "Revenue" as the measure.
2. Navigate to the Query Explorer and into your report "Query1", drag a "Slicer Member
Set" from the Toolbox tab to the Slicer pane.
3. In the Slicer Member Set Expression pane,
o Type set (
o From the "Data Items" tab, drag the Product line level after the parentheses
o Append to the end of the Product line level -> ?Products?
The expression should read as follows:
set([great_outdoors_company].[Products].[Products].[Product line]->
?Products?)
8/6/2019 Create Parameter is Ed Slicer
http://slidepdf.com/reader/full/create-parameter-is-ed-slicer 2/7
4. Using the Page explorer return to Page1. We will now add a string literal and a prompt
for the slicer.
5. From the Toolbox, drag a block object to the left of the cross tab.
6. Drag a Text item from the Toolbox and enter the following string "Values for: "
7. The next step is to drag the "Value Prompt" object from the Toolbox and position it to
the right of the Text item within the block.
8. When the Prompt Wizard dialog box is displayed, select the option "Use existing
parameter" and select "Products" from the drop down list box. Click Next.
8/6/2019 Create Parameter is Ed Slicer
http://slidepdf.com/reader/full/create-parameter-is-ed-slicer 3/7
9. On the second dialog box of the Prompt Wizard, select the default settings and click
"Finish".
10. The completed page layout should look as follows:
8/6/2019 Create Parameter is Ed Slicer
http://slidepdf.com/reader/full/create-parameter-is-ed-slicer 4/7
11. The final steps are to set the properties of the "Value Prompt" and provide a default
value. Highlighting the "Value Prompt" in the page layout will display the properties in
the Properties pane.
Set the following properties for the "Value Prompt":
o Required: Yes
o Multi-Select: No
o Select UI: Drop down list
o Auto-Submit: Yes
12. To ensure that the default prompt page is not generated, a value must be set for the
"Default Selections" property of the Value prompt. Since the prompt is built against a
8/6/2019 Create Parameter is Ed Slicer
http://slidepdf.com/reader/full/create-parameter-is-ed-slicer 5/7
cube the Member Unique Name (MUN) must be used for the default value. To obtain
MUN value you want as the default selection; highlight the member on the Source tab
of the Insertable Objects pane. Right click to activate the context menu. In this
example we will use "Personal Accessories". On the Properties of member highlight the
Member Unique Name, right click to activate the context menu and select copy.
The MUN should look as follows.
[great_outdoors_company].[Products].[Products].[Product line]->:
[PC].[@MEMBER].[3~238]
8/6/2019 Create Parameter is Ed Slicer
http://slidepdf.com/reader/full/create-parameter-is-ed-slicer 6/7
13. Once the MUN is in the paste buffer we now must set the default value for the Value
Prompt. Highlight the "Value Prompt" on the page. Using the Properties page select
"Default Selections". Click the "Add" icon of the Default Selection dialog box. Then
select "Simple Selection".
14. Right click and paste the MUN name for Personal Accessories into the "Add value"
field. Click OK twice to close the Default Selections dialog.
15. Click the "Run Report" button on the toolbar to execute the report. The report should
resemble the following screen capture.