Search This Blog

Wednesday, 28 November 2012

Measure prompt



Taking the reference of this OTN Post I thought of playing around prompts and measure columns.
The exercise is based on Sample Sales Lite SA ( XML Based SA )
Environment- OBIEE 11.1.1.6.0 ( Windows 7 -32 bit /Tested on IE 8 ) 

SA- Sample Sales Lite 

Create an analysis of 3 columns namely
1> "Time"."Per Name Year" 
2>"Base Facts"."Revenue"  
3>"Base Facts"."Revenue"
I would rename the columns ( no. 2 & 3 ) as shown in the snapshot below.

http://1.bp.blogspot.com/--67NAfzBTYw/UJ38aFAkxtI/AAAAAAAABFI/mJrUF3v3XKk/s320/Pic1.png




Column formula of column no 2
http://4.bp.blogspot.com/-J3SHNUiljVY/UJ3875GeRtI/AAAAAAAABFQ/y5UfmGYbtCs/s200/Pic2.png












Column formula of column no 3 ( You can have complex calculation - In the given example I have used a very simple one )
http://1.bp.blogspot.com/-G8RoWx5sMTw/UJ39regy4nI/AAAAAAAABFY/I_-XSGNbPHk/s200/Pic3.png









Save the report. [R1]

Go back to home page and once again navigate to Sample Sales Lite SA.Take 2 to 3 measures for example in the analysis and capture their names from the respective column formulae.We would need this while creating a dashboard prompt. Look at the below snapshot.


http://1.bp.blogspot.com/-YNJJVZ_K_nQ/UJ3_-ExXOtI/AAAAAAAABFg/CEao5N6ykt0/s200/Pic4.png








"Base Facts"."Revenue"
 "Base Facts"."Billed Quantity"
   "Base Facts"."Discount Amount"

Now go to dashboard prompt editor.Select the option Variable Prompt.Add the details as shown in the below snapshot.
http://4.bp.blogspot.com/-J4kjp1croFY/UJ4BewKv1xI/AAAAAAAABFo/xJwPgUMY0Ls/s320/Pic5.png









Save the prompt and pull it on the dashboard with the report R1.

Select the first measure ( Revenue ) and hit apply.You will see the Revenue measure values getting populated in the second column while values of 3rd column would base upon the 2nd column that we select from the prompt.
http://4.bp.blogspot.com/-HgrKfIzYkfE/UJ4C2VlyU3I/AAAAAAAABFw/YpdRUJuRYzQ/s320/Pic6.png




http://1.bp.blogspot.com/-xDDZfyQCUjY/UJ4DNsICKOI/AAAAAAAABF4/_NTnpEoybRI/s320/Pic7.png






You may find blogs on changing the column name dynamically.

 I have to test this solution against an SA based on a relational database and perform multiple rounds of testing. Try it out - You may find some even more interesting facts. Good luck.

No comments:

Post a Comment