{scrollbar} |
In many cases, when the user must choose a value for a parameter from a long list, it is convenient to approximate the search in several steps.
In the case studied in this tutorial, we have so far defined a parameter to filter the report for a given salesperson. One way to facilitate the location of the salesperson, is to catalogue him first either as Distributor or Direct Sale.
In this way we could first request the Channel and later on, choose the salesperson from the list of salespeople in that channel
This section explains how to establish this dependence between parameters through Cascading Parameters.
Se recomienda haber leido antes la sección Simple Parameterizing |
Name: |
Channels |
|
Data Source: |
O3 Local MDX |
|
Data Set Type: |
O3 Data Set |
|
Query |
|
Name: |
ChannelSalespeople (VendedoresDelCanal) |
|
Data Source: |
O3 Local MDX |
|
Data Set Type: |
O3 Data Set |
|
Query |
The query mark will be later associated to the parameter that identifies the Channel. |
Name: |
Channel |
Data Set: |
Channels |
Value: |
unique_name |
Display Text: |
label |
Name: |
ChannelSalesperson (VendedorDelCanal) |
Data Set: |
ChannelSalespeople (VendedoresDelCanal) |
Value: |
unique_name |
Display Text: |
label |
So far we have defined a Cascade with 2 parameters and 2 Data Sets, one for each parameter in the cascade.
What is left is to relate parameters so that one acts on the other.
To test what we have done so far create a new Data Set with the following data:
* Name: Sales by Channel and Salesperson
* Data Source: O3 MDX View
* Data Set Type: O3 Data Set
* Query The following expression in MDX:
SELECT {[Vendedores].?} ON COLUMNS, {[Vinos].[Vino].members} ON ROWS FROM [Vinos] WHERE Measures.[Litros Vendidos] |
In the query, there is a question mark, indicating that in this place there is a parameter. Add the parameter Salesperson by Channel (Vendedor Por Canal) in the data set as indicated in Simple Parameterizing |
Create a table with the information of Sales by Channel (Vents por Canal) and Salesperson (Vendedor) as explained in Designing Report Layout
Select Preview and the following screen will appear
In Channel (Canal) all the channels of salespeople of the Wines (Vinos) cube will appear; choose a channel and Salesperson by Channel ( Vendedor Por Canal ) will automatically be updated.
In Salesperson by Channel all the salespeople in the selected channel will appear; select one salesperson and press OK to see the detail of the litres of wine sold by this salesperson.
For instance, if you choose "Direct Sale" as channel and Federico Moreira as Salesperson, the report will show:
|| Vino || Litros Vendidos ||
Cabernet Sauvignon, Merlot |
4500 |
Cabernet, Tannat, Merlot |
0 |
Chenin, Gewurzt |
2250 |
... |
... |
Ugni Blanco |
0 |
If you wish to change the value of the parameter you will have to click on Show Report Parameters and the previous window will be opened again, where you can choose a new channel and salesperson.
{scrollbar} |